Ant Design Pro: Setting Up an Enterprise Admin Template

Ant Design Pro admin layout with sidebar menu, query form and rules table

Ant Design Pro is a ready-made admin application template built on the Ant Design component library. It bundles layout, routing, authentication screens, data tables and charts into a project you can run immediately, which saves weeks of scaffolding for dashboards and internal tools.

Version 6 of the template builds on React 19 and antd 6, with Umi Max 4 handling routing and plugins and ProComponents consolidated into a single package. The sections below explain what you get, how to start a project and how to shape it into your own application.

What the Template Includes

The template is opinionated by design. It chooses a framework, folder structure and set of conventions so teams can focus on business screens rather than infrastructure decisions.

  • A responsive ProLayout shell with sidebar menu, header and breadcrumbs.
  • Example pages for tables, forms, profiles, results and exceptions.
  • Login screens and an access control pattern for permissions.
  • Mock data so pages render before a backend exists.
  • An AI assistant page in version 6 built with Ant Design X.

Key Building Blocks

ProComponents sit between raw antd components and full pages. They encode common enterprise patterns, such as a table that renders its own search form or a form that handles steps and modal submission.

ComponentPurpose
ProLayoutApplication shell with menus generated from routes
ProTableTable with built-in query form, toolbar and request handling
ProFormForms with step, modal and drawer variants
ProDescriptionsRead-only detail views for records

In version 6, these live in the unified @ant-design/pro-components package, which removes the version mismatches that came from installing several separate packages.

Starting a New Project

The simplest start is cloning the template repository and installing dependencies. Always read the README for the current scripts, since tooling can change between releases.

git clone --depth=1 https://github.com/ant-design/ant-design-pro.git my-admin
cd my-admin
npm install
npm start

Node.js must be installed first. Once the development server runs, open the local address it prints and explore the sample pages before removing the ones your product does not need.

Routes, Menus and Access

Routes are declared in configuration, and the layout builds the sidebar menu from them. Adding a page usually means creating a component and registering its path, name and icon, after which it appears in navigation automatically.

Access control works through a central access definition that returns permission flags for the current user. Routes and buttons check those flags, keeping authorization rules in one place instead of scattered across components.

Customizing the Look

Version 6 enables antd's CSS variable mode and supports several style presets. Brand colors, radius and density are adjusted through theme tokens, the same approach used in plain antd projects and described in the theming article.

Preparing for Production

Before deploying, replace mock data with real API calls, remove unused demo pages and review the generated bundle. A trimmed template loads faster and is easier for new developers to understand.

  • Connect services through the request layer instead of hardcoded fetch calls.
  • Delete example routes and their components once they are unused.
  • Run npm run build and test the output on a staging server.
  • Configure the server to return the app entry for client-side routes.

Working with ProTable

ProTable accepts a request function that receives search parameters, sorting and pagination, then returns data and a total count. The component builds its query form from column definitions, so adding a searchable field often means adding one property to a column.

Value types such as dates, money and status enums control how cells render and how search inputs appear. This declarative approach keeps list pages short and consistent, even when an application contains dozens of them.

  • Mark columns as hidden in search when they should not be filterable.
  • Use value enums to map status codes to labels and colors.
  • Return the total count so pagination stays accurate.

Forms for Create and Edit Screens

ProForm variants handle the most common editing patterns. Modal and drawer forms keep users on the list page, while step forms break long processes into manageable stages with validation at each step.

Field components such as text, select and date inputs come with sensible defaults for width and placeholder text. They still accept regular antd props, so you can fine-tune behaviour without leaving the ProForm conventions.

Upgrading with AI Assistance

Release notes for version 6 describe a pro-upgrade skill that compares your project with the latest template and helps merge framework changes. It can reduce manual work during upgrades, though every change still deserves review and testing before release.

Project Structure Overview

Knowing where things live speeds up daily work. Configuration sits in a dedicated folder, pages are grouped by feature, services wrap API calls and shared components hold reusable pieces such as headers or footers.

AreaTypical contents
configRoutes, proxy settings and build options
src/pagesFeature pages and their local components
src/servicesAPI request functions
mockSample data used during development

Folder names can change between template versions, so confirm against the project you cloned rather than relying on older screenshots.

Frequently Asked Questions

Is Ant Design Pro free?

The template is open source on GitHub. Check the repository license file for the exact terms.

Do I need Ant Design Pro to use antd?

No. Pro is optional and suits admin applications. Plain antd works for any React interface.

What changed in version 6?

It moved to React 19, antd 6 and Umi Max 4, unified ProComponents into one package and added an Ant Design X assistant page.

Can I upgrade an existing Pro project?

Yes, though version gaps can be large. Review release notes and upgrade in small, tested steps.

Conclusion

Ant Design Pro shortens the path from idea to working admin panel by combining layout, routing, permissions and data components in one template. Clone it, explore the samples, register your own routes, theme it through tokens and remove demo code before shipping.

Treat the template as a starting point rather than a finished product, and shape it around the workflows your users actually need. Removing unused pages, documenting routes and keeping dependencies current will make the admin panel easier to maintain for years.