Web3 Functions

Connect real
world APIs
to Web3 in minutes

Fetch data from any API, apply custom logic, and securely push off-chain data on-chain.

Avoid traditional centralized platforms like AWS or Google Cloud

Decentralized infrastructure that provides secure and decentralized foundation for over 400+ Web3 Apps across DeFi, NFTs & Gaming.

> Join Discord
  • 0
  • 1
  • 2
  • 3

How Gelato Web3
Functions Work

  • 0
  • 1
  • 2
  • 3

Launch in 3 easy steps

1

Set your logic

Set your custom Web3 Function logic. Connect to APIs & tell Gelato when to execute

1  import { Web3Function } from "@gelatonetwork/web3-functions-sdk";
2  import { Interface } from "@ethersproject/abi";
3  import axios from "axios";
4
5  Web3Function.onRun(async () => {
6     // Call any off-chain apis
7     const apiUrl = "https://api.coingecko.com/api/v3/coins/ethereum";
8     const coin = await axios.get(apiUrl);
9     const price = Math.floor(coin.data.market_data.current_price.usd);
10
11     // Craft your transaction payload
12     const to = "0xMyOracleAddress";
13     const iface = new Interface(["function updatePrice(uint256)"]);
14     const data = iface.encodeFunctionData("updatePrice", [price]);
15
16     // Return execution call data
17    return { canExec: true, callData: [{ to, data }] };
18  });
2

Deploy

Set your custom Web3 Function logic. Connect to APIs & tell Gelato when to execute

3

Create the task

Set your custom Web3 Function logic. Connect to APIs & tell Gelato when to execute

Decentralized cloud functions
to leverage off-chain data &
computation

Decentralized Backend

Build your app using web3 native infra

Leverage Gelato’s powerful, scalable and trust minimized infrastructure to leverage off-chain data and computation without sacrificing decentralization.

Open & Serverless

Build serverless Web3 Apps

By using Web3 Functions, you can connect your smart contracts to any APIs like price feeds, 1inch swap data or Subgraphs, all without having to run any backend infrastructure yourself

Real-time & Scalable

Get started within minutes

Don't rewrite your existing backend logic, just copy it over and you are good to go. Web3 Functions support NPM modules, provide you with reliable RPCs and in-function storage

Optimize Gas Cost

Reduce on-chain costs

Web3 Functions offer low fees and cost savings by enabling users to decide when to perform on-chain transactions and running Web3 Functions entirely off-chain. Additionally, Gelato's 1Balance payment system allows for easy fee payment using USDC. Start building today, for free with our Accelerator Web3 Functions package.

Supercharge your dapps with
Advanced Web3 Functions Features

  • 0
  • 1
  • 2
  • 3

The data speaks for itself.
Over 20M executions
and running

Beefy Finance

Power vault harvesting and swapping tokens

“Gelato's Web3 Functions enable our smart contracts to become smarter by combining the power of automation and the ability to access external data. With Web3 Functions we can create more powerful products and also eliminate tedious operational tasks.”- Weso, Lead Developer & Head of Strategic Partnerships at Beefy

Abracadabra

Most optimal routes for swaps, withdraws, & buybacks

“With Gelato Network's Web3 Functions, we automated our yield farming vault's compounding and staking reward buybacks on Abracadabra.money. This streamlined our process and made it easier and more reliable than running our own infrastructure, making it an indispensable tool for our yield farming and lending products.”- Abracadabra

Aavegotchi

The best possible price for $GHST token buybacks

Aavegotchi relies on Web3 Functions to perform regular buybacks of the $GHST token. By utilizing Paraswap’s external APIs, swaps are guaranteed the best possible price as the routing is handled automatically off-chain.

Gelato Web3 Functions vs Chainlink Functions

Gelato Web3 Functions
vs Chainlink Functions

Why more developers
choose Gelato

See why devs and founders choose Gelato Web3 Functions over Chainlink Functions to connect their API with Web3

The core design difference

Worker Model (e.g. every minute)

Yes

No

Request / Response model
Coming soon

Yes

Supports triggering Functions off-chain without gas costs

Yes

No

Built-in Multichain RPC Provider

Yes

No

Works with any on-chain event
Coming Soon

No

Execution timeout

30s

10s

Maximum Http Requests

Unlimited

5

Maximum RPC Requests per run

100

N/A

Costs

Developer Friendliness

In Function Features

Smart Contract Integration

Network Support

Explore Web3 Functions
Use Cases

Unleash DeFi Automation: Opium & Gelato's Web3 Functions Integration

Unlock DeFi Automation with Gelato's Web3 Functions

Transforming Real-World Asset Management with Tangible and Gelato's Web3 Functions

Get in touch
Building with Gelato means you are part of an active developer community
Join the community > contact us
Sign up
Be the first to hear about updates