When you create a project, Lovable makes it easy to publish it with the click of a button.

By default, your Lovable app is accessible via a Lovable staging subdomain (e.g., yoursite.lovable.app). However, you can connect your site to a custom domain (e.g., yourdomain.com) or a subdomain (e.g., subdomain.yourdomain.com) that you own.

Using a custom domain enhances your brand, improves SEO discoverability, and makes your site easier to find and remember.

If you want to have a custom domain, see below.

Using Entri

To connect a custom domain, navigate to Project > Settings > Domains in Lovable.

Requirements

Lovable uses Entri to facilitate quick and seamless domain connections.

Step-by-Step Guide

1

Step 1

Navigate to Project > Settings > Domains and click Connect Domain.

2

Step 2

Click Continue.

3

Step 3

Enter the domain you want to connect (e.g., yourdomain.com).

4

Step 4

Click Continue.

5

Step 5

Search for and select your DNS provider (the service where you purchased your domain).

Domain providers are amongst many: 123-Reg, Amazon Route 53, arsys, Aruba IT, Bluehost, Cloudflare, Crazy Domains, DigitalOcean, DNSimple, Domain.com, DreamHost, Dynadot, EasyDNS, Enom, Gandi, Hetzner, Home PI, HostGator, Hostinger, Hover, Inmotion Hosting, IONIS, iwantmyname, Localweb, Name.com, NameBright, Namecheap, NameSilo, Netlify, Network Solutions, One.com, OpenSrs, OVH Global, Porkbun, Register.com, Register.it, Registro, Shopify, SiteGround, Spaceship, Strato, TransIP, United Domains DE, Web.com, WordPress and Xneelo.

6

Step 6

Follow the on-screen instructions to sign in to your DNS provider and authorize the connection to Entri.

7

Step 7

Click Close Window to complete the connection and return to Site Settings.

8

Step 8

Click Done.

DNS changes may take up to 48 hours to propagate globally, though most updates occur within a few hours.

9

You're All Set! 🎉

Your Lovable app is now available on your custom domain.

Using Netlify

You can host on Netlify for free with a custom domain.

Step-by-Step Guide

1

Step 1

Ensure that your project is successfully transferred to GitHub. In the Lovable editor, click on “Transfer to GitHub” located in the top right corner.

2

Step 2

Head over to Netlify and log in using your GitHub credentials.

3

Step 3

In Netlify, you’ll need to follow these simple steps: Click on “Import from Git” > Authorize Netlify to access your GitHub repositories > Select your Lovable repository from the provided list > Click “Deploy”

4

Step 4

Let’s proceed to configure your custom domain directly within Netlify: Go to “Domain Management” > Click “Add a domain” > Enter your domain name > Click “Verify” > Follow the DNS configuration prompts

5

Step 5

Your Lovable app will automatically redeploy to Netlify whenever you make changes in Lovable.

You will need to bring an existing domain or purchase one.

Using Vercel

Step-by-Step Guide

1

Create a Github repository

Open your project in Lovable and click GitHub then “create repository” if you haven’t already done so. This will commit your code to the main branch and create a repository. Once you do this, all changes made to code in your app will automatically be commited to your Github repository on each change.

2

Set up Vercel

Go to the Vercel website and create an account. Configure your domain and set the necessary GitHub permissions (make sure to handle DNS settings properly).

3

Automatic deployments

Vercel will automatically deploy the latest changes from the main branch each time it is updated. You can make one or two small changes to your app on Lovable and then visit Vercel deployments to ensure updates are being redeployed from main. Once confirmed, do the next step:

4

Create a Development branch

In your GitHub repository settings in Lovable, commit all new changes to a second branch called dev (or whatever you want).

5

Configure Vercel Builds

Go back to Vercel and adjust your settings to ensure it only builds production deployments from the main branch.

6

Make changes in Development

Work on your app in the Lovable. Any changes will go to the dev branch now and wont automatically be deployed via Vercel.

7

Deploy new changes

When you’re ready to push new changes to your domain, go to GitHub and perform a pull request from dev to main. Once you complete and merge the pull request, Vercel will automatically deploy the updates in about one minute.

Notes

  • If you hit the 100/day deployment limit in Vercel (it builds your dev branch but doesn’t deploy it). You can ask Lovable chat to build you vercel.json file which will force Vercel to not build development builds at all.

  • Supabase Consideration: Currently, you can only utilize one Supabase instance. So, if you make extensive SQL changes, it could potentially break production. Unfortunately, we can’t yet provide specific guidelines for this scenario as it’s complex. Frequently test your production environment if you make changes related to Supabase.

Using Namecheap

Step-by-Step Guide

1

Transfer Your Lovable Project to GitHub

First, you need to transfer your Lovable project to GitHub if you haven’t already done so.

In your Lovable project, click on the “Transfer to GitHub” button at the top of the interface.

This step is required before proceeding with the custom domain setup.

2

Purchase a Domain from Namecheap

Start by acquiring your domain (e.g., mysimpledomain.com) from Namecheap.

3

Access Advanced DNS Settings

Navigate to the Advanced DNS settings for your domain.

4

Configure DNS Records

Add the following DNS records to your domain configuration:

5

Set Up GitHub Workflow

Create a GitHub workflow file for deployment:

name: Deploy to GitHub Pages

on:
  workflow_dispatch:

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3

      - uses: actions/setup-node@v3
        with:
          node-version: '18'

      - run: npm install

      - run: npm run build

      - name: Copy index.html to 404.html
        run: cp dist/index.html dist/404.html

      - name: Debug build output
        run: |
          echo "Listing contents of the root directory..."
          ls -la
          echo "Listing contents of the dist directory..."
          ls -R dist

      - name: Deploy to GitHub Pages
        uses: peaceiris/actions-gh-pages@v3
        with:
          github_token: ${{ secrets.GH_PAT }}
          publish_dir: ./dist
          cname: mysimpledomain.com
          force_orphan: true
6

Generate GitHub Access Token

Create a classic token at GitHub:

Keep the token page open—you’ll need it for the next step.

7

Add Repository Secret

Add your token as a repository secret named GH_PAT.

8

Configure GitHub Pages

Navigate to your repository’s GitHub Pages settings and:

  • Select Build from a branch
  • Choose the gh-pages branch
  • Save the settings
9

Run the GitHub Workflow

Your website will be updated each time you run the GitHub workflow:

  1. Go to your repository’s Actions page
  2. Select the Deploy to GitHub Pages workflow
  3. Click Run workflow button
  4. This will publish the latest version of your GitHub repository to your custom domain
10

You're All Set! 🎉

Your Lovable app is now available on your custom domain.

For more information, you can check out this site.