/
WebsiteSupport

Docs

Requirements and installation

Your server, the installer and the command-line install.

6 min read

What you need

ComponentMinimumNotes
PHP8.3.36+, 8.4.27+ or 8.5.12+Use one of these releases or newer, as they carry important security fixes that came out on 21 October 2026. Ask your host for a current PHP if yours is older. Extensions: bcmath, ctype, curl, dom, fileinfo, json, mbstring, openssl, pcre, pdo, pdo_mysql, tokenizer, xml, gd, zip
DatabaseMySQL 8.0+ or MariaDB 10.6+Character set utf8mb4. The database user needs all privileges on its database.
Web serverApache or NginxThe document root must be the public/ folder.
PHP settingsession.upload_progress.enabled = 0Recommended. Set it in php.ini or the PHP-FPM pool (cPanel: MultiPHP INI Editor), not in .user.ini or code, then restart PHP. OptiraPOS does not use upload progress.
PHP limitsmemory_limit 256M, upload_max_filesize and post_max_size 16M, max_execution_time 60Needed for attachments, imports and updates.
Diskabout 300 MBPlus room for your uploads and database backups.
Composer, Node.jsnot neededThe package ships with vendor/ and the built front end in public/build. You need Composer 2 and Node.js 20 or 22 only if you change the source code.

Browsers: current Chrome, Edge, Firefox and Safari. HTTPS is strongly recommended (it is required for the camera barcode scanner and for card terminals).

Upload the files

  1. Create a folder for the application on your server, for example /var/www/optirapos or, on cPanel, a folder optirapos next to public_html.
  2. Upload optirapos-1.0.0.zip from your download into that folder and unzip it there. The files sit at the top of the zip (app/, public/, vendor/, artisan and so on), so they land directly in your folder.
  3. Point your domain's document root to optirapos/public.
    • cPanel / Hestia: set the domain's document root to .../optirapos/public in the domain settings.
    • Apache: the included public/.htaccess handles the rewrites. mod_rewrite must be on and AllowOverride All set.
    • Nginx: use the block below.
server {
    server_name your-domain.com;
    root /var/www/optirapos/public;
    index index.php;
    client_max_body_size 64M;
    location / { try_files $uri $uri/ /index.php?$query_string; }
    location ~ \.php$ {
        fastcgi_pass unix:/run/php/php8.3-fpm.sock;
        fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
        include fastcgi_params;
    }
    # attachments are served only by the application, which checks access first
    location ^~ /storage/attachments/ { deny all; }
    location ~ /\.(?!well-known).* { deny all; }
}

Create the database

Create an empty database and a user with all privileges on it (cPanel: MySQL Databases). Note the host (usually 127.0.0.1), port (3306), database name, user name and password.

Open your domain. Until OptiraPOS is installed, every address opens the installer at https://your-domain.com/install.php. It walks you through:

  1. Requirements: checks PHP 8.3 and its extensions, and that storage/, bootstrap/cache/ and the application folder are writable. Fix anything marked Missing, then reload the page. An amber note warns you if your PHP is not one of the patched releases listed under What you need or if session.upload_progress.enabled is on; it does not stop the installation, but have it fixed before you go live.
  2. Database: host, port, name, user and password. Test connection and continue connects before you go on. If the database already holds tables, you are asked to confirm.
  3. Administrator: your name, e-mail and password (8 characters or more), and whether to load demo data.
  4. Install: writes .env with a new application key, creates the tables and your administrator account, loads the demo data if you ticked it, and links public storage.

When it finishes, the installer locks itself: it writes storage/installed, and from then on /install and /install.php answer "404 Not Found". Never delete that file on a live shop. If an installation stops half-way, the installer renames the half-written .env to .env.failed-… so you can correct the problem and run it again.

To send e-mail (receipts, password resets), add the MAIL_ lines shown under Install from the command line to the .env the installer wrote.

Install from the command line (alternative)

Use this path instead of the browser install if you prefer SSH, or to set the mail settings. Copy .env.example to .env in the application folder and set at least:

APP_NAME="OptiraPOS"
APP_ENV=production
APP_DEBUG=false
APP_URL=https://your-domain.com

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=optirapos
DB_USERNAME=optirapos
DB_PASSWORD=your-database-password

MAIL_MAILER=smtp
MAIL_HOST=smtp.your-provider.com
MAIL_PORT=587
MAIL_USERNAME=your-smtp-user
MAIL_PASSWORD=your-smtp-password
MAIL_SCHEME=tls
MAIL_FROM_ADDRESS="no-reply@your-domain.com"
MAIL_FROM_NAME="${APP_NAME}"
APP_URL must be exactly the address your users type, including https://. A mismatch causes "419 Page Expired" on login.

Then, from the application folder (SSH, or the Terminal of your hosting panel):

php artisan key:generate
php artisan migrate --force
php artisan optira:install
php artisan storage:link
php artisan optimize
  • optira:install creates the one administrator account. It asks for the e-mail, the name and the password. It refuses to run a second time unless you add --force.
  • Without prompts: php artisan optira:install --email=you@example.com --name="Your Name" --generate-password. The generated password is shown once; write it down.
  • Once .env has an application key, the browser installer stays closed (404).
  • There is no public sign-up page. Every further account is created by an administrator in Settings → Users & Companies → Users.

Demo data (optional)

To explore with a sample shop first, tick Load demo data in the browser installer, or run php artisan db:seed --force on a fresh installation. It loads demo products, customers and orders. Do not run it on the database you will use for your real business.

Folder permissions

chmod -R 775 storage bootstrap/cache
chown -R your-user:www-data storage bootstrap/cache

Use your web server's group in place of www-data (for example apache, or your cPanel user).

Speed settings (recommended)

OptiraPOS runs on any host that meets the requirements, but these settings make every screen noticeably faster.

  • PHP OPcache on. Most hosts have it (on cPanel: Select PHP Version → Options). Suggested values: opcache.enable=1, opcache.memory_consumption=256, opcache.interned_strings_buffer=16, opcache.max_accelerated_files=20000, opcache.revalidate_freq=60. If you set opcache.validate_timestamps=0, reload PHP after every update you upload by hand; the in-app updater does this for you.
  • Cache the configuration and routes after installing and after every update you upload by hand: php artisan optimize. Run php artisan optimize:clear first whenever you edit .env.
  • Production mode in .env: APP_ENV=production and APP_DEBUG=false.
  • Redis, if your host offers it: CACHE_STORE=redis and SESSION_DRIVER=redis.
  • Compression and browser caching for public/build: the file names change with every release, so the browser may keep them for a year. Most hosts already compress; on Nginx add gzip on; and location /build/ { expires 1y; add_header Cache-Control "public, immutable"; }.
  • Database: on a server of its own, give InnoDB about half of the RAM (innodb_buffer_pool_size).
  • Keep storage/framework/cache writable: OptiraPOS keeps a small list of its tables and columns there, which saves dozens of database questions on every screen.
  • Scheduler every minute. Mail, scheduled messages, reminders and the nightly clean-up are sent by the scheduler. Add one cron line (on cPanel: Cron Jobs → Once Per Minute): * * * * * cd /path/to/optira && php artisan schedule:run >> /dev/null 2>&1. Without it mail and reminders are not sent.
  • Queue worker (optional). No screen waits on a queue, so shared hosting needs none. On a VPS you may keep php artisan queue:work --sleep=3 --tries=3 --max-time=3600 running under systemd or Supervisor, and run php artisan queue:restart after every update.
  • PHP-FPM pool (VPS). Each busy worker uses about 60-90 MB. For 4 GB of RAM shared with the database: pm = dynamic, pm.max_children = 20, pm.start_servers = 4, pm.min_spare_servers = 2, pm.max_spare_servers = 6, pm.max_requests = 500, request_terminate_timeout = 120. Add about 10 children for every extra 1 GB.