Development Guides
Generated Applications
Run Local Development

Run Local Development

Setup & Installation

There are a few steps to run the generated application for local development.

Setup Environment Variables

To run the generated application locally, you need to copy the environment settings. In the ROQ Console go to the Application DetailsEnvironments menu and then Copy Env File in the Local Development section.

Paste the environment settings into the file .env in the root of the generated application project, you need to create this file if it doesn't exist. For instance, bistro-94be has these settings:

# .env
# Public variables, used on client - Delete these if you are not using Next.js

# If you change the host or port on your local installation from http://localhost:3000 to another value,
# then you need to update the settings in the console as well. ROQ Console:
# Modify this to your application URL

# Server variables used for ROQ connection

# Server variables for ROQ auth


Install Database

The generated application uses Prisma ORM (opens in a new tab) so you can use any database that is supported by Prisma. For this tutorial, we will use PostgreSQL (opens in a new tab) and then we will add DATABASE_URL key value in the env file.

PostgreSQL is an open-source relational database. You can install the database from this link (opens in a new tab).

To create a database, we will use pgAdmin, a bundled GUI application for administering PostgreSQL. Let's call this database a bistro.


With the default PostgreSQL installation and with the database name bistro, the database URL for the generated application is:


Run The Application

To run the application type this command in the terminal

npm run dev

By default, the local application will be running on http://localhost:3000 and for first-time use, you need to create an account to be able to use the generated application.

Bistro app

If you want the application to run on another port, change the port value in the .env file as well as the settings in the ROQ Console and go to the Application DetailsSettings.

App auth URLs settings

Change the port value only, for example, if the port number is 3000, you can change it to 2112 or any accesible port. Make sure to change Sign-in URL, Allowed Logout URLs, and Allowed Callback URLs and save them.

Troubleshooting Guide

If you encounter any difficulties while running a local development, kindly refer to our FAQ or Troubleshooting section.