Instant Sites

The Instant Sites feature lets you publish any static folder or file in your project to a live URL—instantly, on demand

The Instant Sites feature lets you publish any static folder or file in your project to a live URL—instantly, on demand. You can deploy via your editor’s file tree or by asking Cosine directly. This guide covers enabling the feature, both deployment methods, customizing your subdomain, using a custom 404 page, and how to manage your deployments.


Table of Contents

  1. Enabling Instant Sites

  2. Deployment Methods

    • A. Right-Click Deploy

    • B. “Ask Cosine” Deploy

  3. Viewing & Sharing Your Deployment

  4. Customizing the Subdomain

  5. Custom 404 Pages

  6. Troubleshooting & FAQs


1. Enabling Instant Sites

  1. Open your project’s Dashboard.

  2. Navigate to Settings → Deployment Settings.

  3. Toggle Instant Sites to On.

Once enabled, “Deploy” options and Cosine's deploy tool become available in your editor.


2. Deployment Methods

A. Right-Click Deploy

  1. In your IDE’s File Tree, locate the folder (e.g. public/, docs/) or single file (index.html) you want to publish.

  2. Right-click it and select Deploy.

You’ll see a notification when it’s live.

B. “Ask Cosine” Deploy

  1. Open the Cosine Chat or Command Palette in your editor (e.g. via the Cosine icon or Ctrl/Cmd+Shift+P).

  2. Type a natural-language request, for example:

  3. Choose the path from the suggestions, confirm any prompt (e.g. name or description), and send.

Cosine will run the deployment and notify you when the site is published.


3. Viewing & Sharing Your Deployment

  • Live URL Once deployed, Instant Sites assigns a URL like:

  • Share Deployment Modal In the preview panel or after the deploy notification, click Share to open the modal:

    • Copy URL button copies the live link.

    • Custom Subdomain input lets you update the subdomain in place.


4. Customizing the Subdomain

  1. Open the Share Deployment modal (from preview panel or post-deploy alert).

  2. Under Custom Subdomain, enter your desired prefix (e.g. my-docs).

  3. Click Update Subdomain.

Your site moves to:


5. Custom 404 Pages

If your static folder contains a 404.html file at its root, Instant Sites will serve that as the custom “Not Found” page. Otherwise, a default 404 page is shown.

  • To use a custom 404:

    1. Add a file named 404.html to the root of the folder you’re deploying.

    2. Deploy or redeploy that folder.

    3. Visit a non-existent path (e.g. https://<id>.cosine.page/nonexistent) to see your custom 404 page in action.


6. Troubleshooting & FAQs

Q: I don’t see Deploy in my file tree.

  • Ensure Instant Sites is toggled on in Settings → Deployment and restart your editor.

Q: Cosine didn’t pick the correct folder.

  • Be explicit in your prompt:

Q: My custom 404 isn’t showing.

  • Confirm your 404.html is in the root of the deployed folder and that you redeployed after adding it.

Q: Custom subdomain update failed.

  • Remember, subdomains under cosine.page must be unique.

  • If you see an error, try a different prefix that isn’t already in use.

Q: My site shows 404 after deploy.

  • Confirm the target folder/file contains an index.html.

  • Review the deployment logs in the Preview panel for errors.


You’re all set! 🚀 Enable Instant Sites, deploy in one click or with a quick Cosine prompt - instantly on cosine.page. Enjoy!

Last updated

Was this helpful?