Shopify powers more than a million online stores around the world.
Many store features you see every day, such as discounts, bundles, and order fulfillment are built using apps. These apps are created by developers to extend Shopify and solve real problems for merchants.
If you know JavaScript and basic web development, you already have enough skills to start building Shopify apps.
In this tutorial, you’ll learn what a Shopify app is, how Shopify apps work, and how to set up your development environment. You’ll also see three real examples of popular Shopify apps and how they are built.
What We’ll Cover
To follow this tutorial, you should be comfortable with JavaScript and APIs. Some experience with Node.js and npm will help, but you do not need to be an expert. No prior experience with Shopify is required.
What Is a Shopify App?
A Shopify app is a web application that connects to a Shopify store. The app runs on your own server or a serverless platform.
It talks to Shopify using secure APIs. When a merchant installs your app, they allow it to access certain store data. This could include products, orders, or customers, depending on the permissions given.
There are different types of Shopify apps.
Public apps are listed on the Shopify App Store and can be installed by any merchant. These apps must pass a review before approval.
Custom apps are built for a single store, and private apps are used only inside a company.
Most Shopify apps include backend code that calls Shopify APIs, a frontend interface shown inside the Shopify Admin, storefront features that shoppers can see, and webhooks that react to store events.
How Shopify Apps Work
When a merchant installs your app, Shopify starts an OAuth process. This is a secure way to ask the merchant for permission.
Once approved, Shopify sends your app an access token. This token allows your app to make API calls to the store.

Shopify apps can add screens inside the admin area using App Bridge and Polaris. These tools make your app feel like part of Shopify. Apps can also add features to the storefront using theme app extensions.
Shopify provides both REST and GraphQL APIs. REST is easy to use, but GraphQL is faster and more efficient. Today, most new apps use GraphQL.
Setting Up Your Development Environment
Before you start coding, you’ll need a few tools. You’ll need to install Node.js and the Shopify CLI. You’ll also need a Shopify Partner account. The Partner account lets you create apps and test them without cost.
The Shopify CLI helps you create a starter app quickly. You can generate a working app by running these commands:
shopify app create node
cd my-shopify-app
npm install
shopify app serve
This creates an app with login, authentication, and an embedded admin interface. It also sets up a secure tunnel so Shopify can reach your local server while you develop.
Understanding Shopify APIs
Shopify provides APIs for almost every part of a store. This includes products, orders, customers, and shipping. Your app can only access data that the merchant has allowed during installation.
Here’s a simple example of fetching products using the GraphQL Admin API:
import fetch from "node-fetch";
async function getProducts(shop, token) {
const query = `
{
products(first: 5) {
edges {
node {
id
title
}
}
}
}
`;
const response = await fetch(
`https://${shop}/admin/api/2025-10/graphql.json`,
{
method: "POST",
headers: {
"Content-Type": "application/json",
"X-Shopify-Access-Token": token
},
body: JSON.stringify({ query })
}
);
const data = await response.json();
return data.data.products.edges;
}
This function gets the first five products from a store. The access token comes from the OAuth process during app installation.
Case Study One: Bundle and Discount Apps
Bundle and discount apps help merchants offer deals like “Buy two, get ten percent off.” These apps must work with Shopify’s pricing rules and checkout system. A popular example is the Bundle Deals app, which shows offers on product and cart pages.

These apps usually add small UI elements to the storefront using theme app extensions. They use Shopify’s Discount APIs to apply offers safely.
They don’t change checkout directly. Instead, they enhance the storefront and let Shopify handle the final pricing.
A storefront script might look like this:
fetch("/apps/bundle-deals/api/bundles?productId=gid://shopify/Product/123")
.then((res) => res.json())
.then((bundles) => {
displayBundles(bundles);
});
This code runs in the store’s frontend. It fetches bundle rules from your app server and shows them to shoppers.
Case Study Two: Printful and Order Fulfilment
Printful is a popular app that connects Shopify stores with a print-on-demand service (for example, T-shirts, Mugs, and so on). When a customer places an order, Printful receives the order and starts production.

Apps like this need access to orders and reliable event handling. They use webhooks to listen for new orders. When Shopify sends a webhook, the app forwards the data to an external system.
Here is a simple webhook example:
app.post("/webhooks/orders/create", async (req, res) => {
const order = req.body;
await printfulClient.createOrder({
external_id: order.id,
items: order.line_items.map(item => ({
variant_id: item.variant_id,
quantity: item.quantity
}))
});
res.status(200).send("Order processed");
});
This keeps Shopify and Printful in sync. The same pattern is used for shipping tools, accounting software, and CRMs.
Case Study Three: Shiprocket and Shipping Rates
Shiprocket helps merchants manage shipping and delivery. Shipping apps often calculate rates in real time and update order status after shipment.

Since Shopify restricts what can run during checkout, shipping apps typically calculate rates before checkout begins or use carrier service APIs. A simple rate endpoint might look like this:
app.post("/shipping/rates", async (req, res) => {
const { destination, items } = req.body;
const rates = await fetchCarrierRates(destination, items);
res.json({
rates: rates.map(rate => ({
service_name: rate.name,
total_price: rate.price
}))
});
});
This lets merchants show shipping options to customers before they reach checkout.
Testing Your Shopify App
Testing is a critical part of building a reliable Shopify app, especially if you plan to submit it to the App Store. Every feature should be tested thoroughly in a development store before you consider a release. A development store lets you simulate real merchant behavior without affecting live data, which makes it ideal for both manual and automated testing.
In addition to live testing, Shopify allows you to mock API responses during development. Mocking lets you test your business logic without relying on real API calls or rate limits. This is especially useful when simulating error scenarios or incomplete data, such as missing fields or unexpected values.
By combining real store testing with mocked responses, you can be confident that your app behaves correctly in both normal and failure conditions.
Preparing for the Shopify App Store
Preparing for the Shopify App Store is an important step if you want to release a public app that merchants can trust and install with confidence. Shopify has a formal review process, and your app must meet both technical and policy requirements before it can be listed.
Your app should request only the API permissions that are absolutely necessary for its core functionality. Asking for extra or unrelated permissions is one of the most common reasons apps get rejected. Shopify expects you to clearly explain why each permission is needed and how the data will be used. This helps merchants feel safe when installing your app.
You must also include basic legal and support information. This includes a clear privacy policy that explains what data you collect and how you handle it, terms of service that define usage rules, and a visible support contact such as an email address or help page.
Finally, Shopify looks closely at app quality. Your app should be stable, handle errors gracefully, and be tested across common store scenarios. Clear messaging, predictable behavior, and transparent data usage go a long way in passing the review process.
Conclusion
Building your first Shopify app takes time, but it’s very achievable. Start with login and API calls. Learn how to embed UI inside Shopify. Study real apps from the Shopify app store. Each one solves a different problem using a different design.
As you practice, the pieces will start to fit together. Keep building, testing, and reading the documentation. Your first Shopify app could be the start of something much bigger.