--- title: scriptTag - GraphQL Admin description: |-

Theme app extensions

If your app integrates with a Shopify theme and you plan to submit it to the Shopify App Store, you must use theme app extensions instead of Script tags. Script tags can only be used with vintage themes. Learn more.

Script tag deprecation

Script tags will be sunset for the Order status page on August 28, 2025. Upgrade to Checkout Extensibility before this date. Shopify Scripts will continue to work alongside Checkout Extensibility until August 28, 2025.

Returns a `ScriptTag` resource by ID. api_version: 2026-01 api_name: admin type: query api_type: graphql source_url: html: https://shopify.dev/docs/api/admin-graphql/latest/queries/scripttag md: https://shopify.dev/docs/api/admin-graphql/latest/queries/scripttag.md --- # script​Tag query Theme app extensions If your app integrates with a Shopify theme and you plan to submit it to the Shopify App Store, you must use theme app extensions instead of Script tags. Script tags can only be used with vintage themes. [Learn more](https://shopify.dev/apps/online-store#what-integration-method-should-i-use). Script tag deprecation Script tags will be sunset for the **Order status** page on August 28, 2025. [Upgrade to Checkout Extensibility](https://www.shopify.com/plus/upgrading-to-checkout-extensibility) before this date. [Shopify Scripts](https://shopify.dev/docs/api/liquid/objects#script) will continue to work alongside Checkout Extensibility until August 28, 2025. Returns a `ScriptTag` resource by ID. ## Arguments * id *** ## Possible returns * ScriptTag *** ## Examples * ### Retrieves a single script tag #### Query ```graphql query GetScriptTag($id: ID!) { scriptTag(id: $id) { id cache createdAt displayScope src updatedAt } } ``` #### Variables ```json { "id": "gid://shopify/ScriptTag/466217408" } ``` #### cURL ```bash curl -X POST \ https://your-development-store.myshopify.com/admin/api/2026-01/graphql.json \ -H 'Content-Type: application/json' \ -H 'X-Shopify-Access-Token: {access_token}' \ -d '{ "query": "query GetScriptTag($id: ID!) { scriptTag(id: $id) { id cache createdAt displayScope src updatedAt } }", "variables": { "id": "gid://shopify/ScriptTag/466217408" } }' ``` #### React Router ```javascript import { authenticate } from "../shopify.server"; export const loader = async ({request}) => { const { admin } = await authenticate.admin(request); const response = await admin.graphql( `#graphql query GetScriptTag($id: ID!) { scriptTag(id: $id) { id cache createdAt displayScope src updatedAt } }`, { variables: { "id": "gid://shopify/ScriptTag/466217408" }, }, ); const json = await response.json(); return json.data; } ``` #### Ruby ```ruby session = ShopifyAPI::Auth::Session.new( shop: "your-development-store.myshopify.com", access_token: access_token ) client = ShopifyAPI::Clients::Graphql::Admin.new( session: session ) query = <<~QUERY query GetScriptTag($id: ID!) { scriptTag(id: $id) { id cache createdAt displayScope src updatedAt } } QUERY variables = { "id": "gid://shopify/ScriptTag/466217408" } response = client.query(query: query, variables: variables) ``` #### Node.js ```javascript const client = new shopify.clients.Graphql({session}); const data = await client.query({ data: { "query": `query GetScriptTag($id: ID!) { scriptTag(id: $id) { id cache createdAt displayScope src updatedAt } }`, "variables": { "id": "gid://shopify/ScriptTag/466217408" }, }, }); ``` #### Response ```json { "scriptTag": { "id": "gid://shopify/ScriptTag/466217408", "cache": false, "createdAt": "2024-10-29T22:38:08Z", "displayScope": "ALL", "src": "https://js.example.org/foo.js", "updatedAt": "2024-10-29T22:38:08Z" } } ```