Eclipse marks a Gradle project with 'Missing Gradle project configuration file'
Your error
Missing Gradle project configuration file: .settings/org.eclipse.buildship.core.prefs2 more lines it can showFix it fast
Most common cause, 1 of 2The .settings folder or the Buildship prefs file is not on disk
Run File > Import > Gradle > Existing Gradle Project and choose the root folder of the build.
File > Import... > Gradle > Existing Gradle Project
Project root directory: /path/to/your/build
FinishShort answer
Missing Gradle project configuration file: .settings/org.eclipse.buildship.core.prefs is a Buildship marker on a project that has the Gradle nature but no readable Buildship settings, often after a clone that ignores .settings. Re-import the build with File > Import > Gradle > Existing Gradle Project; Buildship 3.1 finds the project by its location and writes the file again.
Which cause do you have?
Look at the project folder on disk. Whether the prefs file is absent, ignored by Git, or present but broken decides which of the two causes applies.
ls -a .settings
cat .settings/org.eclipse.buildship.core.prefs
git check-ignore -v .settings/org.eclipse.buildship.core.prefsThen find the line you see in this list and open its fix:
- 1The .settings folder or the Buildship prefs file is not on disk
The marker says Missing Gradle project configuration file or folder, and ls shows no org.eclipse.buildship.core.prefs - 2The prefs file is there but Buildship cannot read it
The marker says Invalid Gradle project configuration file, and the file lacks connection.project.dir or contains merge-conflict lines
What does the error look like?
Missing Gradle project configuration file: .settings/org.eclipse.buildship.core.prefsMissing Gradle project configuration folder: .settingsInvalid Gradle project configuration file: .settings/org.eclipse.buildship.core.prefs
Cause 1 of 2
The .settings folder or the Buildship prefs file is not on disk
You seeThe marker says Missing Gradle project configuration file or folder, and ls shows no org.eclipse.buildship.core.prefs
Check
Missing Gradle project configuration file appears because Buildship checks every project with the Gradle nature for .settings/org.eclipse.buildship.core.prefs and adds this marker when the file or its folder is absent. A .gitignore rule on .settings, a cleanup script, or a project copied with its .project file but without .settings leaves the nature in place and the file gone.
git check-ignore -v .settings/org.eclipse.buildship.core.prefsFix
Run File > Import > Gradle > Existing Gradle Project and choose the root folder of the build. The import finds the workspace project at that location, keeps it, and saves a new prefs file.
File > Import... > Gradle > Existing Gradle Project
Project root directory: /path/to/your/build
FinishVerify
The prefs file exists again and the marker is gone from the Problems view.
ls .settings/org.eclipse.buildship.core.prefsConfirmed by github.com
Cause 2 of 2
The prefs file is there but Buildship cannot read it
You seeThe marker says Invalid Gradle project configuration file, and the file lacks connection.project.dir or contains merge-conflict lines
Check
Invalid Gradle project configuration file means the prefs file exists but Buildship failed to load it. Buildship reads the root project location from the connection.project.dir key, so a file without that key, or one broken by a merge or a hand edit, cannot be loaded.
grep -n "connection.project.dir" .settings/org.eclipse.buildship.core.prefs
grep -n -E "^(<<<<<<<|=======|>>>>>>>)" .settings/org.eclipse.buildship.core.prefsFix
Restore the file from version control if a good copy exists; otherwise delete it and run the Existing Gradle Project import on the build root so Buildship writes a fresh one.
git checkout -- .settings/org.eclipse.buildship.core.prefs
# or
rm .settings/org.eclipse.buildship.core.prefs
# then File > Import... > Gradle > Existing Gradle ProjectVerify
The file holds a connection.project.dir line and Eclipse shows no Buildship marker on the project.
grep connection.project.dir .settings/org.eclipse.buildship.core.prefsConfirmed by github.com
How do I stop it coming back?
- Either commit .settings/org.eclipse.buildship.core.prefs, or document that every fresh clone is opened with the Existing Gradle Project import instead of a plain project import.
- Exclude only the Eclipse settings files you do not want, rather than the whole .settings folder, in .gitignore.
- Resolve merge conflicts in .settings files right away, since Buildship cannot load a prefs file with conflict markers.
Sources
How was this page made?
I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.
Which stack is behind this page?
Projects of mine on the same stack: QistLock, Nuclear Home Video.