Skip to main content

Medusa Admin: v1.0.0

Medusa Admin has been moved from being hosted on a GitHub repository to being published as an NPM package that can be installed in the same project as the Medusa backend. This upgrade guide will help you find the right resources to make the upgrade.

If you made customizations to the admin and you want to preserve these customization, then it's recommended not to update to use the new admin plugin. You can learn more in this section.

Overview

The Admin is now composed of two packages @medusajs/admin and @medusajs/admin-ui. The @medusajs/admin package is the plugin that can be installed in the Medusa server project. The @medusajs/admin-ui package is the UI that is served by the plugin.

This guide will cover three cases where the move might affect your current setup:

  • Updating your existing project to use the plugin
  • Replacing your already deployed admin with the plugin
  • Preserving customizations in the plugin

Actions required

Updating your existing project to use the plugin

As mentioned, Medusa Admin is now distributed via NPM and installed as a plugins. To replace your existing admin, you first need to install the plugin in your Medusa server project.

Follow the admin quickstart guide to learn how to set up the plugin with the Medusa backend.

Deploy the New Admin Plugin

The move to an NPM package has implications for the workflow to deploy the Admin. The plugin offers to ways to deploy the admin, either by serving the Admin directly from the Medusa server, or by deploying the Admin to a separate hosting platform.

To host the Admin directly from your Medusa server, you can follow the Admin Quickstart Guide.

You can learn how to deploy the Admin to a host through the Vercel Deployment Guide. The process is similar for other Git based hosting platforms.

Preserving Customizations in the Admin

If you have made customizations to the Admin, it is recommend that you keep your current setup and wait for the next minor release of Medusa Admin, that will introduce a more seamless way to extend the UI. Migrating customizations to the new admin plugin is not supported, and will require manaully patching any changes or forking the Admin plugin. The current Admin repository will still receive critical bug fixes while in maintenance, but it will not be updated with new features. If you can forego the latest features introduced in 1.8 you can continue to use the standalone admin repository for now.

While it's generally not recommended, if you want to maintain your customizations while upgrading to the latest version of Medusa Admin, you have two options:

  1. Fork the @medusajs/admin plugin and @medusajs/admin-ui, and manually patch in your customizations.
  2. Use the medusa-admin eject -o <output_directory> command to eject the Admin UI from the plugin and use it as a separate project. This way, you can make your customizations and deploy them to a separate hosting platform.
Was this page helpful?