This page describes how to troubleshoot the "Project with that name already exists" error in Looker. This error can occur when you try to create a new project with a name that's already in use by another project, even if that project isn't visible in the UI. This error typically occurs because remnants of the project—often in a Git branch or on the server file system—still exist.
Troubleshooting tree
Use the following decision tree to troubleshoot this error. Open the decision tree in a new tab to zoom in.
Troubleshooting steps
The following sections describe the scenarios in the tree in further detail.
Step 1: Check development branches
Remnants of a project may exist in one or more development branches. To check development branches, follow these steps:
- Turn on Development Mode.
- Navigate to your LookML projects and check every development branch—especially personal branches—for a project with the conflicting name.
- If you find a project with the conflicting name, delete the project in the IDE, commit the change, and then deploy to production to remove the lingering Git reference.
Step 2: Reset Git connection
Resetting the Git connection can force a cleanup of local repository inconsistencies. To reset the Git connection, follow these steps:
- Go to Project Settings for the project.
- On the Configuration tab, select Reset Git Connection.
- Re-enter the Git URL. If you're using SSH, upload the new deploy key to your Git provider.
Step 3: Check pending projects
A model may have been configured using the project name without the project itself ever having been generated. This would have created a pending project. To check for pending projects, follow these steps:
- Turn on Development Mode.
- View the LookML Projects page.
- Check the Pending Projects section. If a project exists with the conflicting name, delete the pending model configuration.
Step 4: Server-side resolution (bare repos only)
If your Looker instance uses a bare Git repository (customer-hosted), the files may be lingering on the server. To clean up files on the server, sign in to the Looker host server and manually rename or delete the bare repository folders that are associated with the project:
- Rename or delete the directory:
~/models/YOUR_PROJECT_TO_DELETE - Rename or delete the bare repository directory:
~/bare_models/YOUR_PROJECT_TO_DELETE.git
Step 5: Delete the project by using the Looker API
If the previous steps don't resolve the error, you can use the Looker API to manually delete the project to force an internal cleanup. This method uses the 4.0 API endpoints and requires Looker Admin privileges.
1. Get an access token
Use your API credentials (Client ID and Secret) to obtain a bearer token.
curl -d "client_id=CLIENT_ID&client_secret=CLIENT_SECRET" https://INSTANCE_HOSTNAME.cloud.looker.com/api/4.0/login
The response will contain an access_token.
2. Switch session to Development Mode
You must delete the project in Development Mode. Switching to Development Mode changes the API session context.
curl -X PATCH "https://INSTANCE_HOSTNAME.cloud.looker.com/api/4.0/session" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer BEARER_TOKEN" \
-d '{"workspace_id": "dev"}'
3. Delete the project
Once the session is in Development Mode, use the DELETE /projects/{project_id} endpoint to delete the project.
curl -X DELETE "https://INSTANCE_HOSTNAME.cloud.looker.com/api/4.0/projects/PROJECT_ID_TO_DELETE" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer BEARER_TOKEN"
A successful call will return an empty response (204 No Content) or a successful deletion message. You should now be able to re-create the project in the Looker UI.
These API calls can also be performed using API tools such as Postman.
Final review and support
If these troubleshooting steps fail to resolve the error, contact Support to troubleshoot further.