This document is written for enterprise website owners who are encountering KingCMS X1 for the first time. You don't need to read the developer documentation first—just complete the following 8 steps in order, and you can publish your first website online. The commands in this document use Debian 13, nginx, and PHP 8.4 as examples, with paths uniformly using /var/www/kingcms.

Before You Begin

Who this is for: people responsible for building enterprise websites who need to deploy it themselves once before handing it over to colleagues for maintenance.

What you need to prepare:

  • A server you can log into via SSH, with nginx or Apache already installed, and PHP 8.2 or higher (X1.0.0-beta.1 requires min_php 8.2).
  • PHP extensions: pdo_sqlite, sqlite3, sodium, mbstring, intl, curl, gd, xml, ctype, json, openssl, zip.
  • A domain already resolved to the server, and a writable data/ directory.
  • The site root directory must point to public/ in the release package; app/ and data/ must be placed outside the site root and must not be directly accessible by browsers.

1. Download and Verify

The current version is X1.0.0-beta.1, released on 2026-10-24. Release package download page: https://download.kingcms.com/. Verify after downloading; if it doesn't match, do not extract and deploy.

wget https://update.kingcms.com/stable/kingcms-x1-X1.0.0-beta.1.zip
sha256sum kingcms-x1-X1.0.0-beta.1.zip

The checksum should be:

b433a7cc1081ab5cf4e3fbad3ff4709135307c972390d44f658934e242363ecc

2. Upload and Extract, Point Site Root to public/

sudo mkdir -p /var/www/kingcms
sudo unzip kingcms-x1-X1.0.0-beta.1.zip -d /var/www/kingcms

The archive contains app/, bin/, modules/, public/, resources/, themes/, vendor/. Dependencies are provided with the package; you don't need to run composer install.

Point the site root directory to /var/www/kingcms/public, not to /var/www/kingcms or app/. It's recommended to enable OPcache to reduce the overhead of recompiling PHP files on every request.

3. Directory Permissions and nginx

data/ needs to be writable by the user running the website (usually www-data):

cd /var/www/kingcms
sudo mkdir -p data/uploads data/cache
sudo chown -R www-data:www-data data
sudo find data -type d -exec chmod 750 {} \;
sudo find data -type f -exec chmod 640 {} \;

public/img/ stores images generated by size, and must likewise be writable by www-data:

sudo mkdir -p /var/www/kingcms/public/img
sudo chown www-data:www-data /var/www/kingcms/public/img

On first access, the program automatically creates data/app.key and sets it to 0600. app.key is used to encrypt key fields in settings; do not delete it or replace it—once lost, already-encrypted values cannot be decrypted.

Key nginx points:

  • root points to /var/www/kingcms/public, index is index.php.
  • location / uses try_files $uri $uri/ /index.php?$query_string;, otherwise inner pages will return 404.
  • location /media/ uses alias to point to /var/www/kingcms/data/uploads/, and disables PHP execution in that directory.
  • Deny access to dotfiles, but keep the ACME verification directory.
  • Keep client_max_body_size consistent with PHP's upload_max_filesize and post_max_size, for example set both to 20m.
  • limit_req_zone can only be written in the http context; put it in a separate conf file.

For the complete configuration, Apache rewrite rules, and PHP upload limit instructions, see /docs/install. After changing the configuration, run nginx -t to check, then reload.

4. Automatic Database Creation on First Access, Create Administrator

Open the site address in a browser. When data/kingcms.sqlite does not exist, the program automatically creates the SQLite database, runs migrations, writes default settings, and generates data/app.key. There is no step-by-step installation wizard, and no manual SQL import is needed.

When no administrator has been created yet, accessing any page of the site redirects to /admin/setup. Fill in the one-time setup page:

  • Username: cannot be empty, maximum 64 characters.
  • Password: at least 8 characters, and confirm it again.
  • "Write sample content (deletable)" checkbox: you can check it to see the front-end effect first.
  • "Are product prices tax-inclusive": tax-exclusive / tax-inclusive, required.
  • Site timezone: automatically filled in based on the browser.
  • Agree to the license agreement (X1 v2.3).

After successful creation, the current browser automatically logs in and redirects to the admin homepage /admin; /admin/setup permanently returns 404 and can no longer be used to create a second administrator. The login address afterward is /admin/login.

5. Fill In Basic Site Information

Go to the admin "System Settings → Settings" (系统设置 → 设置) and fill in the following fields completely:

GroupFieldDescription
Basic InformationSite NameThe name the enterprise displays externally
Basic InformationWebsite URLThe official access address
Basic InformationFront-end LogoThe image used in the front-end page header
Basic InformationSite TimezoneFill in according to the actual timezone
Basic InformationURL FormatChoose as needed
Contact & OrganizationOrganization NameUsed for the homepage Organization structured data
Contact & OrganizationContact PhoneExternal contact information
Contact & OrganizationContact AddressExternal contact address
FilingICP Filing NumberFill in according to the actual filing information
FilingPublic Security Filing NumberFill in according to the actual filing information
FilingPublic Security Filing LinkFill in according to the actual filing information

Enabled languages and default language are in "Settings → Content & Media" (设置 → 内容与媒体). Default title, default keywords, default description, and share title/description/image are in "Marketing & SEO → SEO → Settings" (营销与 SEO → SEO → 设置). The default front-end theme outputs meta description, canonical, hreflang, and og:title/description/url/image, and outputs JSON-LD types such as Organization, WebPage, Article, Product/Offer, BreadcrumbList, FAQPage, CollectionPage, and ItemList.

6. Create Your First Single-Page Column and Publish

In "System Settings → Column Management" (系统设置 → 栏目管理), click "Add". The form fields are parent column, name, type (article list/single page/product list), column introduction, and thumbnail. Choose "Single Page" for the type, suitable for content like About Us and Contact Us. The path is automatically generated from the name (Chinese converted to pinyin); there are no path name and sort fields—sorting is done by dragging.

After saving, click "Edit" to get the body, SEO title/keywords/description, FAQ, visible to visitors, and include in navigation. The body editor supports common formats such as headings, lists, links, images, and tables. There is a "View" in the list.

Single pages and products both have an FAQ block; once filled in, FAQPage JSON-LD is output; article and column lists do not have it. For multilingual sites, fill in translations using language tabs on the edit page; if no translation is filled in, the front end falls back to Chinese. When renaming, check "Regenerate path" and the old path automatically gets a 301; the address only changes if you check regenerate path.

After saving and publishing, return to the front end to confirm the page opens normally. If the homepage works but inner pages return 404, first check the rewrite configuration in step 3.

7. Configure cron and HTTPS

cron is responsible for executing the per-minute hooks registered by enabled modules and processing due background tasks. Write the following into /etc/cron.d/kingcms:

SHELL=/bin/sh
PATH=/usr/local/bin:/usr/bin:/bin
* * * * * www-data /usr/bin/php /var/www/kingcms/bin/kingcms cron:run >/dev/null 2>&1

cron:run uses data/cron.lock to ensure only one runs at a time; confirm that data/ is writable by www-data.

HTTPS should be configured before going live officially. WeChat and Alipay callbacks and Secure cookies all depend on HTTPS.

8. Pre-Launch Checklist

  1. The site root points to public/, and app/ and data/ are not inside the site root.
  2. data/ and public/img/ are owned by www-data, and app.key has permissions 0600.
  3. Both the homepage and inner pages open, with no 404.
  4. Upload an image and confirm it displays normally under /media/ and that PHP is not executed.
  5. Site name, URL, Logo, contact phone, address, ICP filing number, default title, and description are filled in.
  6. The first single-page column is published, with SEO title and description filled in.
  7. cron is configured, and data/ is writable.
  8. HTTPS is enabled.
  9. Visit /sitemap.xml, /robots.txt, and /llms.txt to confirm they output normally.
  10. The database and app.key are backed up together, and the backup files are placed outside the site directory.

If you need search engines to index the site, in "System Settings → Modules & Themes" (系统设置 → 模块与主题) confirm that the "Search Engine Indexing" module is enabled (after a fresh install of beta.1, it is in fact already enabled). On the "Marketing & SEO → SEO → Settings" (营销与 SEO → SEO → 设置) page, click "Show Advanced Settings" to configure Baidu/Sogou site verification, Baidu regular indexing push (toggle), Baidu site address, Baidu push token, IndexNow push, and Toutiao/360 JS auto-submit. The push log is on the "Push Log" tab of that page. AI assistants such as Tencent Yuanbao have no public submission entry, and KingCMS also has no dedicated settings for Doubao, DeepSeek, or Yuanbao.

Try It Locally First

If you just want to see the interface on your local machine, run a single command in the extracted directory:

php -S 127.0.0.1:8080 -t public public/index.php

Then open http://127.0.0.1:8080. On first access, data/, data/kingcms.sqlite, and data/app.key are automatically created, and then you enter /admin/setup to create an administrator. The built-in server is only suitable for local trial use; do not use it for an official site.

Related Documentation

  • /docs/install: installation and updates, complete nginx and Apache configuration, backup, cron, FAQ.
  • /docs/product-page: how to write and operate a product introduction single page.
  • /docs/ai-visibility: explanation of site visibility to AI assistants.

KingCMS X1 is provided free of charge and may be used commercially by enterprises at no cost, on the condition that the front-end “Powered by KingCMS” copyright link is retained; to remove this link, purchase a commercial license, details at /license.