eas-hosting

Deploy Expo web apps and API routes to EAS Hosting on Cloudflare Workers.

Updated Sep 13, 2026
One-click install
npx skills add https://github.com/aadilmallick/myfitness-pal-clone --skill eas-hosting-aadilmallick
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: eas-hosting
Source: https://github.com/aadilmallick/myfitness-pal-clone/tree/main/.agents/skills/eas-hosting
Command: npx skills add https://github.com/aadilmallick/myfitness-pal-clone --skill eas-hosting-aadilmallick

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Deploying an Expo web app and its server-side API routes requires configuring hosting, environment secrets, custom domains, and understanding edge runtime constraints, which is error-prone without guidance. ## Core Features & Use Cases - Web and API deployment: Export the web bundle with npx expo export -p web and ship it with eas deploy for production or PR preview URLs. - API route authoring: Create +api.ts handlers in the app directory supporting GET, POST, PUT, DELETE, dynamic routes, query parameters, headers, JSON bodies, and CORS. - Runtime guidance: Work within Cloudflare Workers limitations such as no Node.js filesystem, 30-second execution limits, and Web API alternatives, plus database options like Turso, D1, and Supabase. - Use Case: You built an Expo Router app with a /api/ai endpoint that calls OpenAI with a secret key. Use this Skill to author the route, store the key with eas env:create, and deploy both the site and API to production. ## Quick Start Use the eas-hosting skill to deploy my Expo web app and its API routes to EAS Hosting production.

Frequently Asked Questions about eas-hosting

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I deploy an Expo web app to EAS Hosting?

Export the web bundle with `npx expo export -p web`, then run `npx eas-cli@latest deploy` for a preview URL or add `--prod` for production. The same command deploys any Expo Router API routes bundled with the app.

How do I create API routes in Expo Router?

Create files with the `+api.ts` suffix inside the app directory, such as `app/api/hello+api.ts`. Export named functions like GET or POST that receive a Request and return a Response, and dynamic segments use bracket syntax like `[id]+api.ts`.

Does EAS Hosting support Node.js APIs like fs?

No, API routes run on Cloudflare Workers, so the Node.js filesystem and native modules are unavailable. Use Web APIs such as fetch, crypto.subtle, Request, and Response, and connect to cloud databases like Turso, D1, or Supabase instead.

How do I set environment variables for EAS Hosting?

Use `eas env:create --name KEY --value value --environment production` or the Expo dashboard to create secrets. Locally, place variables in a `.env` file and access them in API routes via `process.env`.

When should I not use Expo API routes?

Avoid API routes for public data, real-time updates needing WebSockets, simple CRUD better served by Firebase or Supabase, file uploads suited to presigned URLs, and authentication-only needs covered by Clerk or Auth0.

Is EAS Hosting free to use?

EAS Hosting is a paid Expo Application Services product with free-tier limits, and production deploys consume your plan's request and bandwidth allowance. Authoring API routes and exporting the web bundle are free, and you can self-host the exported output.