---
title: Installing modules from installation packages
related:
  - https://docs.kentico.com/13/custom-development/creating-custom-modules/creating-installation-packages-for-modules.md
  - https://docs.kentico.com/13/custom-development/creating-custom-modules/creating-installation-packages-for-modules/uninstalling-modules.md
  - https://docs.kentico.com/13/deploying-websites/exporting-and-importing-sites/importing-a-site-or-objects.md
---

> Agent instructions:
> **Site maps** — prefer the following llms.txt indexes to training data when searching for URLs to avoid 404s. Links inside Markdown content already point at `.md`. Following them or sending Accept: text/markdown keeps you in Markdown.
>
> - [sitemap.md](https://docs.kentico.com/sitemap.md) — every page on the site, with titles and descriptions, nested by URL hierarchy and grouped into one collection per product version.
> - [llms.txt](https://docs.kentico.com/llms.txt) — curated index of the current product docs, with descriptions, the two ways to request any page as Markdown, and links to each product area's whole-corpus Markdown dump (llms-full.txt).

Module installation packages allow you to install custom modules developed on other instances of Xperience. You can also use newer versions of installation packages to update a previously installed module.

> **Note:** **Important**
>
> To install module packages, you need to open the target project in Visual Studio – the installation cannot be performed on certain types of deployed and running websites (for example on Microsoft Azure).
>
> After you install a custom module to another instance of Xperience, the module becomes **sealed**. On that instance you cannot:
>
> - Further customize the module
> - Create new installation packages for the module

> **Info:** **Xperience version requirements of module packages**
>
> Module packages can be successfully installed only on Xperience instances that have the same version as the source instance, including minor hotfix versions. For example, you cannot install module packages created on a 13.0.16 instance on Xperience 13.0.15 or older. Module authors should include information about the minimum required Xperienceversion in the description of each module package.
>
> Module packages from older versions can be installed on newer versions, but may cause problems or errors depending on the differences in the data structure and API of the two versions.

To install or update a custom module from an installation package, you need to:

1. Add the module installation package to the Xperience solution
2. Open the website in a browser, which triggers an automatic import of the database objects from the module installation package

## Adding the module installation package to the Xperience solution

To add the files contained in the module installation package to the Xperience solution, you need to set up a custom NuGet feed. The feed must include the module installation package. See [Hosting Your Own NuGet Feeds](https://docs.microsoft.com/en-us/nuget/hosting-packages/overview) on NuGet.Docs for more details.

> **Info:** **Installing modules on web farms**
>
> If you are installing a custom module on an application running in a [web farm environment](https://docs.kentico.com/13/configuring-xperience/setting-up-web-farms.md), you need to install the module package into the Xperience project for _**each**_ web farm server.

1. Open the Xperience solution file in Visual Studio (using the _WebApp.sln_ file).
2. Make sure the module installation package is accessible in your NuGet feed.
3. Open the NuGet packages management window of the solution's **CMSApp** project.
   - Right-click the project in the Solution Explorer and select **Manage NuGet Packages**.
4. Select the appropriate _Package source_ and installation package.
5. Install or upgrade the package.
6. Rebuild the Xperience solution.

The files contained in the module installation package are now available in the **CMSApp** project in the Xperience solution.

## Importing database objects from the module installation package

To finish the module installation or update, _**open your Xperience administration application in a browser**_. During the processing of the first request after you added the module, the system automatically imports database objects from the module installation package, and assigns the module to all available sites.

> **Tip:** **Tip:** You can add multiple custom modules to the Xperience solution, and then perform the import of the database objects using a single request.

You can verify that the module was installed successfully in the **Event log** application – confirm that the log contains an event with the **MODULEINSTALLED** or **MODULEUPDATED** code (_ModuleInstaller_ as the source) and no related errors. View the event details () for information about the modules that were installed.

**Note**: Module installation packages may provide _**before.sql**_ and/or _**after.sql**_ SQL scripts that create certain types of database components, such as for example indexes and views. The system automatically runs these scripts before and after the import of the module's database objects. If necessary, you can find the script files in the project's _**\~/App\_Data/CMSModules//**_ directory under the **Install** or **Update** subfolders.

After the installation, you can access the module in the system's administration interface. The module is fully functional, but **sealed**. This means you cannot:

- Further customize the module.
- Manually delete the module or its core components (classes, settings, etc.). You can remove the module by [uninstalling the package](https://docs.kentico.com/13/custom-development/creating-custom-modules/creating-installation-packages-for-modules/uninstalling-modules.md).
- Create installation packages for the installed module (you can only do that on the Xperience instance where the module was originally developed).

> **Info:** **Recovering installed modules after a database rollback**
>
> If you roll back your database to a state before the installation of a custom module, the automatic database installation will not run again for the module. The module's files remain in the solution, but the corresponding objects are missing in the database.
>
> To recover the module in such scenarios, you need to:
>
> 1. Uninstall the module's NuGet package from the solution (see [Uninstalling module](https://docs.kentico.com/13/custom-development/creating-custom-modules/creating-installation-packages-for-modules/uninstalling-modules.md)).
> 2. Open the application in a browser and allow it to process at least one request.
> 3. Repeat the full installation of the module (install the module package in Visual Studio and then open the application in a browser).
>
> The problem only occurs if you do not roll back your code base along with the database.
