Skip to content
Go to https://apps.moonbeam.network/moonbeam page to Launch app
Back to news

How to Migrate Hosted Subgraphs to the Graph Network

Kevin Neilson, PaperMoon

May 9, 2024

3 min read

The Graph recently announced its Sunrise Upgrade ProgramGo to page https://thegraph.com/sunrise-upgrade-program/, meant to spur network participants to migrate from the hosted service to the decentralized Graph Network before the scheduled decommission date of the hosted service on June 12, 2024. Not only is the decentralized Graph Network more robust and more reliable than the hosted service, but migrating to the Graph Network is essential as the hosted service will soon be decommissioned.

The Graph Network now offers full indexing support for Moonbeam, making it an ideal time to transition your subgraphs from the hosted service to this robust, decentralized platform. Designed to handle production-grade traffic seamlessly, The Graph Network presents an array of compelling features. It eliminates rate-limiting, provides a complimentary tier with up to 100k queries per month—ideal for testing phases, hackathons, and startups—and offers flexible payment options in GRT or credit card for additional queries. Both Moonbase and Moonriver networks are fully supported.

Migrating your hosted service subgraphs to The Graph’s decentralized network is not only cost-free but can be accomplished in just a few simple clicks. It’s important to note that all hosted service subgraphs must complete this upgrade by June 12, 2024. After this deadline, any subgraphs that remain on the hosted service will be deprecated. This blog post will guide you through the migration process, ensuring a smooth transition to the decentralized network. This guide assumes that you have an existing subgraph on the Graph hosted service.

To get started, head to thegraph.comGo to page https://thegraph.com/ and click on Products -> Hosted Service

image

Press Sign in to authenticate with your GitHub account. Be sure to sign-in with the GitHub account that created the Subgraphs you want to migrate.

image

Press Upgrade Subgraphs

image

Carefully review the conditions of the migration. If you see a message that no subgraphs require upgrading, you either have already migrated all of the relevant subgraphs, or you currently have no deployed hosted subgraphs. (e.g., Due to inactivity, your hosted subgraphs are currently not deployed). You can no longer deploy new hosted subgraphs, but you can easily deploy new and existing ones in Subgraph StudioGo to page https://thegraph.com/studio/.

image

Press Proceed. Then select the Subgraphs to Upgrade. Once published to the decentralized Graph Network, the Upgrade Indexer ensures that the subgraphs are immediately available to query. You can also add curation GRT to attract additional indexers for added reliability.

You’ll need to select a receiving wallet to have ownership of the Subgraph. Going forward, you’ll login to the Graph Studio by signing a message with this account rather than authenticating via GitHub. After you’ve selected an account(s), you can confirm the upgrade process, which typically takes about a minute. Then, you can head to Subgraph StudioGo to page https://thegraph.com/studio/ to view your Upgraded Subgraphs published to the Graph Decentralized Network. Check out the Graph’s GuideGo to page https://thegraph.com/docs/en/cookbook/upgrading-a-subgraph/ for more information about upgrading your subgraphs.