2020-06-08 18:08:27 +00:00
---
type: howto
stage: Manage
group: Import
2020-11-26 06:09:20 +00:00
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
2020-06-08 18:08:27 +00:00
---
2018-07-05 14:30:22 +00:00
# Import multiple repositories by uploading a manifest file
2020-05-22 03:08:28 +00:00
> [Introduced](https://gitlab.com/gitlab-org/gitlab-foss/-/issues/28811) in GitLab 11.2.
2018-08-16 15:56:00 +00:00
2018-08-16 15:49:57 +00:00
GitLab allows you to import all the required Git repositories
based on a manifest file like the one used by the
[Android repository ](https://android.googlesource.com/platform/manifest/+/2d6f081a3b05d8ef7a2b1b52b0d536b2b74feab4/default.xml ).
This feature can be very handy when you need to import a project with many
repositories like the Android Open Source Project (AOSP).
2018-07-09 11:59:07 +00:00
2018-08-16 15:49:57 +00:00
## Requirements
2018-07-09 11:59:07 +00:00
2018-08-16 15:49:57 +00:00
GitLab must be using PostgreSQL for its database, since
[subgroups ](../../group/subgroups/index.md ) are needed for the manifest import
to work.
2018-07-05 14:30:22 +00:00
2018-08-16 15:49:57 +00:00
Read more about the [database requirements ](../../../install/requirements.md#database ).
2018-07-05 14:30:22 +00:00
2018-08-16 15:49:57 +00:00
## Manifest format
2018-07-05 14:30:22 +00:00
2018-08-16 15:49:57 +00:00
A manifest must be an XML file. There must be one `remote` tag with a `review`
attribute that contains a URL to a Git server, and each `project` tag must have
a `name` and `path` attribute. GitLab will then build the URL to the repository
by combining the URL from the `remote` tag with a project name.
2021-04-25 18:09:52 +00:00
A path attribute is used to represent the project path in GitLab.
2018-07-05 14:30:22 +00:00
2018-08-16 15:49:57 +00:00
Below is a valid example of a manifest file:
2018-07-05 14:30:22 +00:00
```xml
< manifest >
2018-11-12 04:52:19 +00:00
< remote review = "https://android.googlesource.com/" / >
2018-07-05 14:30:22 +00:00
< project path = "build/make" name = "platform/build" / >
< project path = "build/blueprint" name = "platform/build/blueprint" / >
< / manifest >
```
2021-04-25 18:09:52 +00:00
As a result, the following projects are created:
2018-07-05 14:30:22 +00:00
2018-11-12 04:52:19 +00:00
| GitLab | Import URL |
|:------------------------------------------------|:------------------------------------------------------------|
| `https://gitlab.com/YOUR_GROUP/build/make` | < https: // android . googlesource . com / platform / build > |
| `https://gitlab.com/YOUR_GROUP/build/blueprint` | < https: // android . googlesource . com / platform / build / blueprint > |
2018-08-16 15:49:57 +00:00
2021-05-10 00:10:37 +00:00
## Import the repositories
2018-08-16 15:49:57 +00:00
2021-05-10 18:10:41 +00:00
To start the import:
2018-08-16 15:49:57 +00:00
2021-05-10 18:10:41 +00:00
1. From your GitLab dashboard click **New project** .
1. Switch to the **Import project** tab.
1. Click on the **Manifest file** button.
1. Provide GitLab with a manifest XML file.
1. Select a group you want to import to (you need to create a group first if you don't have one).
2021-04-25 18:09:52 +00:00
1. Click **List available repositories** . At this point, you are redirected
2018-08-16 15:49:57 +00:00
to the import status page with projects list based on the manifest file.
1. Check the list and click **Import all repositories** to start the import.
2020-08-19 00:10:34 +00:00
![Manifest status ](img/manifest_status_v13_3.png )