Skip to content

How to Set Up Mealie on a Linux Server – Recipes, Meal Plans, and Shopping Lists for the Family

Set up Mealie on your Linux server: use the One-Click App with HTTPS or install it manually with Docker Compose. Includes secure first login, BASE_URL, importing recipes from links, meal planning, shopping lists, family invitations, and backups.

27 November 202612 min read2 Views0 helpful

Introduction

Mealie is a free recipe manager with a meal planner and shopping list. You can import recipes directly from cooking websites using a link: Mealie reads the ingredients, preparation steps, times, and image, then saves everything to your own collection—without ads or pop-ups. Use your recipes to plan meals for the week and create a shopping list in just a few clicks that the whole family can view on their phones.

In this guide, we’ll show you two ways to get started: the easy way, using the One-Click App to get Mealie up and running with HTTPS in just a few clicks, and the manual installation using Docker Compose, following the official instructions. After that, you’ll import your first recipes, plan the week, use the shopping list, and invite your family.

When it makes sense to run Mealie on a VPS

Mealie also runs on a computer at home. A VPS is useful if:

  • You want your recipes to be accessible from anywhere—at the supermarket, at friends’ homes, or on vacation—without setting up port forwarding on your home router.
  • Several people want to plan and shop together. Everyone in your household can see the same meal plan and shopping list, and changes appear for everyone right away.
  • You want to build your recipe collection independently of cooking websites and apps. Once a recipe is in Mealie, it stays there, even if the original website disappears.
  • You don’t want a device at home running around the clock. The VPS is always online.

Mealie is less suitable if you only save a recipe now and then. Browser bookmarks are enough in that case. Mealie’s strengths really shine when you cook, plan, and shop regularly.

The easy way: Mealie as a One-Click App

The fastest way to get Mealie is through your VPS’s One-Click Apps. The app is accessible over HTTPS with a domain, and stores recipes, images, and the database in its own volume. You don’t need a reverse proxy, certificate, or firewall rules.

Requirements

  • A Linux VPS (Debian or Ubuntu) with One-Click Apps set up. See Setting up One-Click Apps for instructions.
  • Enough memory: the values in the Requirements table below also apply to the One-Click App.

Install

  1. Open your VPS in the ZapX Dashboard and switch to the One-Click Apps tab.
  2. Search the app catalog for Mealie and click Install app.
  3. Use a custom subdomain or zap.cloud is already selected with a random name. Leave it enabled or enter your own name: you can use the domain to access Mealie over HTTPS, including from your phone.
  4. You don’t need to fill in anything under App configuration. ALLOW_SIGNUP is set to false: new users can only join your instance by invitation. TZ is set to Europe/Berlin, which is suitable for Germany and Austria. Leave PUID, PGID, MAX_WORKERS, and WEB_CONCURRENCY at their default values.
  5. Click Queue installation. After one or two minutes, Mealie will show as online on the app card.

First login and setup

During installation, Mealie creates an admin account with publicly known credentials. The login page displays them the first time you open it:

  • Email address: changeme@example.com
  • Password: MyPassword

Open the app’s Access link and sign in. Mealie will then start a setup wizard:

  1. Start: Use Choose Language to switch the interface to German. If you have a backup from an older Mealie instance, restore it here using Restore Backup. Otherwise, click Next.
  2. Account Details: Enter a username, your name, your own email address, and a secure password. This replaces the default credentials. Enable Advanced Content unlocks features such as API keys and webhooks; you can also change this later.
  3. Site Settings: Leave Enable Public Access turned off, or anyone will be able to see your recipes without signing in. Leave Use Seed Data turned on: Mealie will then add common foods, units, and labels in the selected language.
  4. AI Providers: You can skip this step. AI features require an account with an AI provider.
  5. Summary: Check your details and finish by clicking Submit.

In our test, we could no longer sign in with changeme@example.com and MyPassword afterward; only the new credentials worked.

Warning

Change the default login immediately Until you change the default credentials, anyone who knows your app’s address can sign in as an administrator. Complete the setup wizard right after installation. The app card will continue to show a warning about the default login afterward; this is normal.

Set BASE_URL

Mealie needs to know its own address to create links in emails correctly, for example, for invitations and password resets. The One-Click App doesn’t set this value. Under Settings > Site Settings (at /admin/site-settings), Mealie will therefore warn you that BASE_URL is still set to its default value. Here’s how to enter the address:

  1. Open the app settings (gear icon) and switch to App environment.
  2. Under Custom environment variables, click the plus icon.
  3. Enter BASE_URL as the key and your app’s address, including https://, as the value. Use the address shown in the Access link.
  4. Click Save. Mealie will restart, but your recipes and accounts will be retained.

The Site Settings page will no longer show a warning. By the way, invitation links that you copy in the interface also work without BASE_URL; they use the address in your browser.

Set up email delivery (optional)

Mealie doesn’t send emails without a mail server. Invitations via link and everything else still work. If you want to use email for invitations and password resets, the official documentation says to enter your mail provider’s credentials as custom environment variables: SMTP_HOST, SMTP_PORT (default 587), SMTP_FROM_EMAIL, SMTP_USER, and SMTP_PASSWORD. Check that everything works by sending a test email under Site Settings.

Updates and backups

To update Mealie, open the app settings (gear icon) and select App update. Click Check for updates, then install a new version using Apply update. If it says the app is up to date, there isn’t a newer version in the app catalog yet. Recipes, images, and accounts are stored in their own volume and are retained during updates.

Create a backup in Mealie before every update: open Settings > Backups (at /admin/backups), create a new backup, and download the ZIP file. Store it somewhere outside the server. You can also use the same file to restore your data on a new instance.

Manual installation

The rest of this guide describes the manual installation of Mealie with Docker Compose on your VPS—for example, if you’re not using One-Click Apps on the server or want to control all the settings yourself.

Requirements

  • A Linux VPS running Debian or Ubuntu, with SSH access. See First access via SSH.
  • Docker and Docker Compose. See Installing Docker. Verify the installation with docker --version and docker compose version.
  • For HTTPS: a domain or subdomain whose A record points to your VPS’s IP address (e.g., mealie.example.com).
MinimumRecommended
Memory (RAM)512 MB1 GB
StorageA few GB for the image and databaseMore, depending on the number of recipe images

Mealie is available for 64-bit systems (amd64 and arm64). The official documentation recommends limiting the container’s memory because Python otherwise reserves more memory than necessary. The Compose file below sets the limit to 1000 MB.

Prepare the firewall

Mealie listens on port 9000 inside the container. You don’t need to open this port if you use a reverse proxy, as shown below. With ufw, allow only SSH and the ports used by the reverse proxy:

Code
ufw allow OpenSSH
ufw allow 80/tcp
ufw allow 443/tcp
ufw enable
Warning

Docker bypasses ufw Ports published by Docker using ports: are accessible from the internet even if ufw blocks them. Therefore, bind Mealie only to 127.0.0.1, as in the Compose file below. This is especially important here because Mealie uses the publicly known default login until setup is complete. For more information, see Managing the firewall on Linux.

Install with Docker Compose

Create a directory for Mealie and switch to it:

Code
mkdir -p /opt/mealie
cd /opt/mealie

Create the Compose file with nano docker-compose.yml. It follows the official SQLite template, using a port that is only accessible locally:

Code
services:
  mealie:
    image: ghcr.io/mealie-recipes/mealie:v3.31.0
    container_name: mealie
    restart: always
    ports:
      - "127.0.0.1:9925:9000"
    deploy:
      resources:
        limits:
          memory: 1000M
    volumes:
      - mealie-data:/app/data/
    environment:
      ALLOW_SIGNUP: "false"
      PUID: 1000
      PGID: 1000
      TZ: Europe/Berlin
      BASE_URL: https://mealie.example.com

volumes:
  mealie-data:

Here’s what the entries mean:

  • image: The official image at a fixed version. The Mealie developers advise against using latest: choose a version deliberately after reading the release notes. Find the versions on GitHub; the format is always vX.Y.Z.
  • 127.0.0.1:9925:9000: Mealie is available on the server at port 9925, but only locally. External access goes through the reverse proxy.
  • memory: 1000M: Limits memory, as recommended in the official documentation.
  • mealie-data: The volume for the database, recipe images, and backups. Mealie uses SQLite, which the official documentation recommends for 1 to 20 people.
  • ALLOW_SIGNUP: Setting this to false means new users can only join by invitation.
  • BASE_URL: The address where Mealie will be available. Replace mealie.example.com with your domain.

Start the container:

Code
docker compose up -d

Check whether everything is running with docker compose ps, and view Mealie’s messages with docker compose logs -f mealie.

First access

Because Mealie listens only on 127.0.0.1, you’ll open the interface for the first time through an SSH tunnel. Run this command on your own computer:

Code
ssh -L 9925:localhost:9925 root@SERVER_IP

Replace SERVER_IP with your VPS’s IP address, then open http://localhost:9925 in your browser. Sign in with changeme@example.com and MyPassword, then complete the setup wizard as described above under “First login and setup.” Under Settings > Site Settings, Mealie will check your configuration and show warnings, for example, about BASE_URL or email delivery.

Access via HTTPS through a reverse proxy

To access Mealie without a tunnel, put a reverse proxy with a valid certificate in front of it. For the basics, see Setting up a reverse proxy with nginx and Creating an SSL certificate (Let's Encrypt). Here’s a server block for nginx:

Code
server {
    listen 80;
    server_name mealie.example.com;
    client_max_body_size 1024m;

    location / {
        proxy_pass http://127.0.0.1:9925;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }
}

client_max_body_size allows larger uploads. Without this line, nginx rejects anything over 1 MB, such as recipe photos from your phone or a backup you want to restore. Then get the certificate with certbot --nginx -d mealie.example.com. Certbot adds HTTPS and redirects HTTP to the block. Make sure BASE_URL in the Compose file matches this address exactly.

Tip

Caddy instead of nginx Caddy is even simpler: it obtains the certificate automatically. Just add mealie.example.com { reverse_proxy 127.0.0.1:9925 } to the Caddyfile.

Back up your data

All Mealie data is stored in the mealie-data volume. The official documentation recommends stopping the container and backing up the data directory:

Code
cd /opt/mealie
docker compose stop
docker run --rm -v mealie_mealie-data:/data -v /opt/mealie:/backup alpine tar -czf /backup/mealie-data-$(date +%F).tar.gz -C /data .
docker compose start

Check the volume name with docker volume ls. Docker Compose adds the project name as a prefix, so for a directory named /opt/mealie, the volume is mealie_mealie-data. You can also create a ZIP backup in Mealie at any time under Settings > Backups. Copy your backups to another computer; a backup on the same server won’t protect you from a server failure.

Update Mealie

Read the release notes and create a backup before every update. Then enter the new version in docker-compose.yml and restart the container:

Code
cd /opt/mealie
docker compose down
docker compose pull
docker compose up -d

Mealie will update the database to the new version when it starts. Remove old images with docker image prune.

Using Mealie day to day

Once setup is complete, fill your recipe collection, plan the week, and invite your family.

  1. Click Create in the sidebar and select Import with URL.
  2. Paste the recipe link under Recipe URL and click Create.
  3. Mealie imports the recipe with its image, ingredients, steps, and times. If Parse recipe ingredients after import is enabled, Mealie then breaks the ingredients down into quantities, units, and foods. You’ll confirm any ingredients Mealie isn’t sure about in a short dialog.

In our test, importing from an English and a German cooking website worked right away. With Import original keywords as tags, Mealie also imports the website’s keywords. Import several recipes at once using Bulk URL Import. To import collections from other apps such as Tandoor, Nextcloud Cookbook, or Paprika, use the migrations at /group/migrations.

Create a meal plan

Under Meal Planner, you’ll see the current week. In edit mode, add breakfast, lunch, dinner, or a snack for each day. Alternatively, open a recipe’s three-dot menu and select Add to Plan. Out of ideas? Random Meal picks a random dish from your collection. Use Meal Plan Rules to narrow down the random selection—for example, to recipes tagged “vegetarian” on Mondays. For leftovers or an evening ordering takeout, add a note instead of a recipe.

According to the documentation, you can also subscribe to the meal plan in your calendar app using an iCal link.

Use the shopping list

Under Shopping Lists, click Create to make a list, such as “Weekly groceries.” You can add ingredients to the list in three ways: manually, from a recipe using Add to List, or directly from the meal plan for a day or the whole week. Quantities are based on the servings you’ve set in the plan. Check off items at the store. If you accidentally check off an item, click it again under the checked-off items to add it back to the list.

Use labels to organize the list, for example, by fruit and vegetables, refrigerated items, or frozen foods.

Invite your family: households and users

Here’s how to invite other people to your instance:

  1. Open your profile (at /user/profile) and click Get Invite Link.
  2. Under User Group and User Household, choose where the new person should be added. Mealie will generate an invitation link.
  3. Click Copy to copy the link and send it—for example, using a messaging app. The invited person can create their own account using the link.

If email delivery is set up, Mealie can also send the invitation directly by email using the Email field.

A note about planning: a Group is a completely separate recipe collection. Each Group contains Households. All households in a Group share recipes, but have their own meal plans and shopping lists. The existing household is enough for a family. If, for example, you want to share recipes with your grandparents but plan and shop separately, create a second household for them.

Limitations

  • Not every cooking website can be imported. Some websites block automatic requests, for example, with bot protection. Mealie usually works around this itself. If it still doesn’t work, add the recipe as HTML or JSON using the “import from raw data directly” link on the import page, or enter it manually.
  • No emails without a mail server. Email invitations and password resets require the SMTP_* variables. Without them, invite people using an invitation link.
  • AI features cost extra. Importing from photos, videos, or free-form text requires an account with an AI provider, which you pay for yourself. Regular link imports work without one.
  • Don’t store SQLite on network storage. The official documentation warns that storing the data directory on a network drive can corrupt the database. Use your VPS’s local disk.

Conclusion

You’ve set up Mealie on your VPS, replaced the default credentials, imported recipes from links, and set up a meal plan and shopping list for your household. From now on, your recipes are available on all your devices, and you can plan together with your family.

Prefer not to handle Docker yourself? Take the easy route with the One-Click App, as described above under “The easy way: Mealie as a One-Click App.”

Free tools

Related tools for servers and developers

View all

FAQ

Frequently asked questions

The One-Click App is the fastest option: Mealie runs over HTTPS at your domain within minutes, stores data in its own volume, and you can install updates from the dashboard. Manual installation with Docker Compose is a good choice if you want to control the version, configure the reverse proxy yourself, or run Mealie alongside other services in your own Docker environment.
During installation, Mealie creates an admin account with the email address changeme@example.com and the password MyPassword. These credentials are publicly known. Sign in with them right after installation and replace them with your own credentials under Account Details in the setup wizard. The default login won’t work afterward.
Click Create, select Import with URL, paste the recipe link, and click Create. Mealie imports the title, image, ingredients, preparation steps, and times. Use Bulk URL Import to import multiple links at once, or use migrations to import collections from apps such as Tandoor, Nextcloud Cookbook, or Paprika.

Feedback

Was this article helpful?

Your feedback helps us prioritize and improve content.

0 of 0 people found this article helpful.

Personal support

Need more help than the guide provides?

Our ZAP-Hosting support team knows your product — briefly describe your issue and we'll help you personally.

Zappy knows this guide and answers you right in the chat.