How to fix remote: GitLab: The project is archived and cannot be modified in Git
This error occurs when you try to push commits to a GitLab repository that has been archived. Archived projects are read-only, so you must unarchive the project or push to a different repository.
Quick fix
Fixes remote: GitLab: The project is archived and cannot be modified
# Update your remote to point to the fork
git remote set-url origin git@gitlab.com:your-username/forked-project.git
# Or add it as a new remote
git remote add myfork git@gitlab.com:your-username/forked-project.git
# Push to your fork
git push myfork main- Verify the project is archived
- Request the project be unarchived (if you're not an owner)
- Unarchive the project (if you have owner/admin access)
- Unarchive a parent group if needed
# Update your remote to point to the forkgit remote set-url origin git@gitlab.com:your-username/forked-project.git# Or add it as a new remotegit remote add myfork git@gitlab.com:your-username/forked-project.git# Push to your forkgit push myfork mainremote: GitLab: The project is archived and cannot be modified
What this error means
When you push to a GitLab repository and receive "The project is archived and cannot be modified," it means the repository owner or administrator has placed the project into archived status. In GitLab, archiving a project makes it entirely read-only. When a project is archived: - The repository displays an "Archived" badge - All Git operations that modify the repository (push, merge) are blocked - Issues, merge requests, and wikis become read-only - Scheduled CI/CD pipelines stop running - Pull mirroring stops - Fork relationships are severed and open merge requests from forks close This is a deliberate action taken by project maintainers, typically to preserve historical projects that are no longer actively developed. The error is GitLab enforcing this read-only state. Common scenarios where you encounter this error: - Pushing to an old project that was archived after you cloned it - Automated CI/CD pipelines targeting repositories that were archived - Contributing to an open source project that has been deprecated - Attempting to push to a project archived as part of a group archive
Typical symptoms
- Git push fails with 'remote: GitLab: The project is archived and cannot be modified'
- All branches reject pushes, not just protected branches
- Merge requests cannot be created or merged
- GitLab web UI shows an 'Archived' badge on the project
- CI/CD pipelines no longer trigger or run
- Cannot create issues or comments on the project
Common causes
- A project owner or administrator archived the project (most common)
- The parent group was archived, which automatically archives all projects within it
- The project was archived as part of organization cleanup or deprecation
- You cloned the project before it was archived and are now trying to push changes
- Automated systems are targeting a project that has since been archived
How to fix "remote: GitLab: The project is archived and cannot be modified"
First, confirm the project's archived status:
1. Go to the project in GitLab's web interface
2. Look for an Archived badge near the project name
3. Or navigate to Settings > General > Advanced and check the archive status
If you see the archived badge or status, the project is in read-only mode and no Git operations that modify the repository will work.
If you're a contributor but not a project owner:
1. Contact the project owner or administrator
2. Explain why you need to push changes
3. Ask them to unarchive the project temporarily or permanently
Only users with Owner or Administrator role can unarchive a project. If the project was intentionally deprecated, consider forking it instead.
If you're a project owner or administrator:
1. Go to Your Projects and select the Inactive tab (archived projects are listed here)
2. Find and open your project
3. Navigate to Settings > General
4. Expand the Advanced section
5. Click Unarchive project
Alternatively, from any project list view, click the actions menu (three dots) next to the project and select Unarchive.
After unarchiving:
- Read-only restrictions are lifted immediately
- Scheduled CI/CD pipelines resume automatically
- Pull mirroring resumes automatically
If the project was archived as part of a group archive, you cannot unarchive it individually:
1. Navigate to the parent group settings
2. Go to Settings > General > Advanced
3. Click Unarchive group
This will unarchive all projects and subgroups within that group. You must have Owner or Administrator access to the group.
If the project is intentionally archived and should remain so, fork it:
1. Go to the archived project in GitLab
2. Click the Fork button (forking still works on archived projects)
3. Select your namespace for the fork
4. Push your changes to your forked repository
# Update your remote to point to the fork
git remote set-url origin git@gitlab.com:your-username/forked-project.git
# Or add it as a new remote
git remote add myfork git@gitlab.com:your-username/forked-project.git
# Push to your fork
git push myfork mainThis lets you continue development without requiring changes to the original archived project.
If automated systems are failing due to archived projects:
1. Update pipeline configurations to target the correct (unarchived) repository
2. Or update the repository URL to point to a fork
3. Remove any triggers or schedules for archived projects
For GitLab CI/CD using multi-project pipelines:
# Update downstream project references
trigger:
project: new-namespace/unarchived-project # Updated path
branch: mainAdvanced notes
### Why Projects Get Archived
Archiving is typically done for:
- Deprecated projects: Software that's no longer maintained
- Completed projects: One-time projects that are finished
- Organization cleanup: Reducing clutter in project lists
- Compliance: Preserving historical projects without allowing modifications
### Finding Archived Projects
Archived projects don't appear in standard project listings. To find them:
1. Go to Your Projects
2. Click the Inactive tab
3. Archived projects show a badge indicating their status
### Group Archiving Behavior
When a group is archived:
- All projects and subgroups within it are archived
- Projects cannot be unarchived individually
- You must unarchive the entire group first
- This is useful for archiving entire organizational units
### GitLab Pages and Archived Projects
When a project is archived:
- Deployed GitLab Pages are removed
- Custom domains are cleared
- After unarchiving, you must manually rerun the pipeline to restore Pages
### Self-Hosted GitLab Considerations
On self-hosted GitLab instances, administrators have additional options:
- Archive/unarchive via the Admin Area
- Bulk archive projects via Rails console
- Different permission models may apply
### API Access to Archived Projects
Read-only API access still works on archived projects. You can:
- Clone the repository
- Read issues and merge requests
- Access CI/CD logs and artifacts
- Download files and releases
Frequently asked questions
- What does "remote: GitLab: The project is archived and cannot be modified" mean?
- When you push to a GitLab repository and receive "The project is archived and cannot be modified," it means the repository owner or administrator has placed the project into archived status. In GitLab, archiving a project makes it entirely read-only. When a project is archived: - The repository displays an "Archived" badge - All Git operations that modify the repository (push, merge) are blocked - Issues, merge requests, and wikis become read-only - Scheduled CI/CD pipelines stop running - Pull mirroring stops - Fork relationships are severed and open merge requests from forks close This is a deliberate action taken by project maintainers, typically to preserve historical projects that are no longer actively developed.
- How do I fix "remote: GitLab: The project is archived and cannot be modified"?
- This error occurs when you try to push commits to a GitLab repository that has been archived. Archived projects are read-only, so you must unarchive the project or push to a different repository.
- What causes "remote: GitLab: The project is archived and cannot be modified"?
- A project owner or administrator archived the project (most common) The parent group was archived, which automatically archives all projects within it The project was archived as part of organization cleanup or deprecation
- Is the "remote: GitLab: The project is archived and cannot be modified" error serious?
- It is a medium-severity error โ more of a blocker than a risk. The steps above resolve it.
Official resources & further reading
- ๐Git Official Documentation
- ๐Manage projects - GitLab Docs(Official Docs)
- ๐Troubleshooting Git - GitLab Docs(Official Docs)
- ๐
- ๐ฌHow to reopen a closed project - GitLab Forum(Stack Overflow)
- ๐Manage a GitLab Project: How to archive or unarchive(Official Docs)