You're reading docs for Nextly Alpha. APIs may change between releases.

Admin Panel

Customization

Configure admin panel behavior, plugin placement, and sidebar organization.

The admin panel is configured through the admin key in your nextly.config.ts. This page covers structural customization, specifically how you control what appears in the sidebar and where. For visual customization (logo, colors, favicon), see Branding.

Admin Configuration

The admin block in defineConfig() accepts two top-level keys:

nextly.config.ts
import { defineConfig } from '@nextlyhq/nextly';

export default defineConfig({
  admin: {
    branding: { /* logo, colors, favicon -- see Branding page */ },
    pluginOverrides: { /* per-plugin sidebar overrides */ },
  },
});

Collection Sidebar Options

Each collection definition can control how it appears in the admin sidebar through its admin property:

src/collections/posts.ts
import { defineCollection, text, richText } from '@nextlyhq/nextly';

export default defineCollection({
  slug: 'posts',
  labels: { singular: 'Post', plural: 'Posts' },
  admin: {
    icon: 'FileText',        // Lucide icon name for the sidebar
    group: 'Content',        // Group label in the sidebar
    hidden: false,           // Hide from sidebar (still accessible via URL)
    order: 10,               // Sort position (lower = higher, default: 100)
    useAsTitle: 'title',     // Field to display as entry title in list view
    defaultColumns: ['title', 'status', 'createdAt'],
  },
  fields: [
    text({ name: 'title', required: true }),
    richText({ name: 'content' }),
  ],
});
OptionTypeDefaultDescription
iconstring"FileText"Lucide icon name shown in the sidebar
groupstring-Groups collections under a label in the sidebar
hiddenbooleanfalseHides the collection from sidebar navigation
ordernumber100Sort position within the sidebar section
useAsTitlestring-Field name used as the entry title in list views
defaultColumnsstring[]-Columns shown by default in the list view

Plugin Overrides

When a plugin registers sidebar entries, you can override their placement and appearance without modifying the plugin's source code. Overrides are keyed by the plugin's slug.

nextly.config.ts
import { defineConfig } from '@nextlyhq/nextly';

export default defineConfig({
  admin: {
    pluginOverrides: {
      'form-builder': {
        placement: 'settings',    // Move to Settings section
        order: 80,                // Sort position within that section
        after: 'media',           // For standalone placement: appear after Media
        appearance: {
          icon: 'FileText',       // Override the sidebar icon
        },
      },
    },
  },
});

Override Options

OptionTypeDescription
placementstringTarget sidebar section ("collections", "singles", "media", "plugins", "settings")
ordernumberSort position within the target section
afterstringFor standalone plugins: which built-in section to appear after ("dashboard", "collections", "singles", "media", "plugins", "users", "settings")
appearanceobjectPartial override of the plugin's sidebar appearance (icon, label)

Overrides use a shallow merge, so only the fields you specify are changed. Everything else keeps the plugin author's defaults.

The admin sidebar is permission-gated. Navigation items only appear for users who have the required permission. The built-in permission mapping:

SectionRequired Permission
DashboardAlways visible
CollectionsBased on per-collection read permissions
SinglesBased on per-single read permissions
Media Libraryread-media
Usersread-users
Rolesread-roles
Custom Fieldsmanage-settings
Settingsmanage-settings
Schema Buildermanage-settings

Assign permissions through the Roles management page at /admin/security/roles.

Responsive Behavior

The admin panel adapts to screen size:

  • Desktop (1024px and above) uses a dual-sidebar layout with icon sidebar and detail sidebar
  • Mobile (below 768px) uses a hamburger menu with a slide-in drawer navigation

No configuration is needed. The layout switches automatically.

Next Steps