URL Handle Changer
Change the URL handles of many Shopify products, collections, pages or blog posts at once, and keep every old link working. Load your handles with one GraphiQL query, clean them up by rule or paste a list, then run the batches with a redirect from each old address, a backup and an undo.
What you’ll need
Shopify’s free GraphiQL app (with read_products, write_products (pages: read_online_store_pages, write_online_store_pages; blog posts: read_content, write_content) access)
How to get this: Shopify’s free GraphiQL app
- Install it once from shopify-graphiql-app.shopifycloud.com: enter your store address, tick the access listed here, click Install and approve.
- Then open it any time from Apps › Shopify GraphiQL App in your admin.
Your new handles, or the clean-up you want (for example removing copy-of- and -1 from duplicated products)
1Load your current handles
What can I type?
Shopify’s search filter, for example status:active, vendor:Acme or tag:sale. Leave it empty to load everything, 250 at a time.
Copy this query into the Shopify GraphiQL app, press Run, then copy the whole response. Keep it: it’s your record of the old handles.
# Products: id, handle and title (250 per page). Run in the GraphiQL app and copy the whole response.
query {
products(first: 250, sortKey: TITLE) {
pageInfo { hasNextPage endCursor }
nodes { id handle title }
}
}
No store handy?
2Choose the new handles
Cuts at a whole word. Empty means no limit (Shopify allows 255).
Leave empty to delete what you found.
Separate them with a comma, a tab or →. Full links work too (https://yourstore.com/products/old-handle).
Load your handles in step 1, then check the changes here.
3Back up and confirm
The backup and the GraphQL appear here once there are changes to make.
4Check the result
How it works
- You run one read query in Shopify’s GraphiQL app; its response lists the id, handle and title of each item, 250 per page.
- Your rules or your list turn each old handle into a new one, cleaned the way Shopify cleans handles (lowercase, hyphens, no accents).
- Every new handle is checked: not empty, 255 characters or fewer, not used twice in the batch, and not already used by another item you loaded.
- The changes are written as productUpdate, collectionUpdate, pageUpdate or articleUpdate mutations in batches of 25, each with redirectNewHandle: true, plus undo batches and a backup CSV.
- Paste each batch’s response back and the tool lists what changed and quotes any error Shopify returned.
Guides
Questions
Does this connect to my store?
No. You run the queries yourself in Shopify’s free GraphiQL app and paste the responses here. Everything is worked out in your browser; nothing is sent to us.
Will my old links still work?
Yes, with “Create a redirect from each old address” ticked (the default). Every change sets redirectNewHandle: true, and Shopify adds a URL redirect from the old path for products, collections, pages and blog posts alike. You’ll find them in Content › Menus › URL redirects.
Why not change the handle in a product CSV?
Shopify’s importer finds products by their handle, so a new handle in the CSV creates a second product instead of renaming the first, and no redirect is made.
What if a new handle is already taken?
The tool checks every new handle against the ones you loaded and the rest of the batch, and leaves clashes out. If Shopify still refuses one, it says “Handle 'x' already in use. Please provide a new handle.”, the item keeps its old handle, and the rest of the batch goes through. Paste the response in step 4 to see which.
Can I undo it?
Yes. Step 3 includes undo batches that put every old handle back. Shopify adds no redirect on the way back, and the first redirects stay in your list (they do nothing while the old address works again).
What does Shopify do with a messy handle?
Shopify cleans it without an error: “Canvas Tote!” is saved as canvas-tote. The tool does the same clean-up first, so the handle you see is the handle you get.
Based on Shopify Help: URL redirects, Shopify Admin API: productUpdate and Shopify Help: Using CSV files to import and export products.
Moving from another platform? Use the Redirect Map Builder. Selling in more than one language? Build handles per language with the Translated URL Handle Builder.