SQL Server error 918 ("Failed to load the engine script metadata") means the instance cannot read the metadata file that describes the scripts it needs to start — usually because the file is missing, locked, corrupted, or the service account cannot access it. The fastest fix is to confirm the SQL Server service account has full control of the instance's install and data folders, restart the service, and if the error persists, repair the instance from the installation media. This guide walks through the safe order: permissions first, then service restart, then repair, then reinstall as a last resort.
What You'll Need
- Administrator rights on the Windows server or PC hosting SQL Server.
- The SQL Server service account name (visible in SQL Server Configuration Manager).
- The original SQL Server installation media or ISO, matching the installed version and edition, in case a repair is needed.
- A current backup of your user databases and any custom scripts, in case a repair or reinstall touches instance files.
- Access to the SQL Server error log (usually in the instance's Log folder) to confirm the exact file path mentioned in the error.
Step-by-Step
- Read the full error message. Error 918 is almost always followed by a file path. Note that path exactly — it is the metadata file SQL Server cannot load. If you only see the number, open SQL Server Management Studio (if it connects) or the SQL Server error log in the instance's Log directory and find the surrounding lines.
- Check that the file exists. In File Explorer, navigate to the path from the error. If the file is missing, that confirms the problem is a damaged or incomplete installation rather than a permissions issue. Do not create a blank file with the same name — that will not work and can make repair harder.
- Open SQL Server Configuration Manager. Expand SQL Server Services, right-click the instance (for example SQL Server (MSSQLSERVER) for the default instance), and choose Properties. On the Log On tab, note the account. Labels can differ slightly by version, but the Log On tab is present across supported releases.
- Grant the service account full control of the instance folders. In File Explorer, right-click the SQL Server install directory (typically under Program Files\Microsoft SQL Server) and choose Properties > Security > Edit. Add the service account if it is not listed, then tick Full control. Repeat for the data and log directories, which are often on a separate drive. Apply to subfolders as well.
- Restart the SQL Server service. In Configuration Manager, right-click the instance and choose Restart. If it starts cleanly, try connecting. If error 918 returns, continue.
- Check for antivirus or backup software locking files. Temporarily exclude the SQL Server data, log and install folders from real-time scanning, then restart the service. Re-enable protection after testing, and keep the exclusions if the vendor recommends them for database servers.
- Run a repair from the installation media. Mount the ISO or insert the media, run setup.exe, choose Maintenance > Repair, select the instance, and complete the wizard. Repair replaces missing or damaged instance files, including script metadata, without touching your user databases. Back up first anyway.
- Apply the latest cumulative update for your version. If the repair succeeds but the error returns after an update, install the current cumulative update for your SQL Server version from Microsoft's official download pages. Do not install updates from third-party sites.
- Reinstall the instance as a last resort. If repair fails repeatedly, uninstall just the database engine instance (keeping user database files), then reinstall and reattach the databases. This is destructive to instance-level settings such as logins, jobs and linked servers — export or script those first.
Common Mistakes
- Creating an empty file at the missing path. SQL Server expects specific content; a blank placeholder will not satisfy the check and can mask the real problem during repair.
- Granting permissions to the wrong account. The service may run as a built-in account (Local System, Network Service) or a domain account. Grant rights to the account shown in Configuration Manager, not to your own login.
- Repairing before backing up. Repair is usually safe for user databases, but a backup costs minutes and protects against surprises.
- Using installation media from a different edition or version. A repair with mismatched media can fail or leave the instance in a worse state. Match the exact version and edition.
- Ignoring the error log. The log often names the exact file and the reason (access denied, file not found), which saves guesswork.
Tips
- Keep the SQL Server installation media or ISO archived alongside the server so a repair is always possible without hunting for downloads.
- After any fix, run a test backup and a DBCC CHECKDB on your user databases to confirm the instance is healthy.
- If the server recently had a drive letter change or a folder move, check that the instance's startup parameters still point to the correct paths.
- Document the service account and folder permissions so future administrators do not have to rediscover them during an outage.
Troubleshooting
If the service still will not start after permissions and a restart, open Event Viewer > Windows Logs > Application and look for SQL Server entries at the time of the failure. Access-denied errors point back to permissions; file-not-found errors point to a damaged installation and a repair. If repair completes but the error persists, check whether a third-party tool is restoring or locking files in the SQL Server folders. If the instance starts but some features fail, review the error log for additional errors that may share the same root cause. When reinstalling, confirm the new instance uses the same collation and paths as before so existing databases attach cleanly.
Frequently Asked Questions
What causes SQL Server error 918?
Most commonly a missing or corrupted instance metadata file, or a service account that lacks permission to read the SQL Server install or data folders. Less often, antivirus or backup software locks the file at startup.
Will repairing SQL Server delete my databases?
No. Repair targets instance and program files, not user database files. Still, take a backup first as a precaution.
Can I fix error 918 without the installation media?
Sometimes — permissions fixes and service restarts do not need media. A repair does, so keep the matching ISO or media available.
Does error 918 affect all databases on the instance?
Yes. If the engine cannot start, no database on that instance is available until the problem is resolved.
Should I reinstall SQL Server immediately?
No. Work through permissions, restart, antivirus exclusions and repair first. Reinstalling is the last step because it resets instance-level settings.
Where do I find the SQL Server error log?
In the instance's Log folder under the SQL Server install directory, typically named ERRORLOG. It records startup failures and the exact file paths involved.