How do I uninstall and reinstall the MathWorks Service Host?
    3,293 views (last 30 days)
  
       Show older comments
    
    MathWorks Support Team
    
 on 30 Sep 2022
  
    
    
    
    
    Edited: MathWorks Support Team
    
 on 29 Oct 2025 at 20:32
            How do I uninstall and reinstall the MathWorks Service Host?
Accepted Answer
  MathWorks Support Team
    
 on 8 Sep 2025
        
      Edited: MathWorks Support Team
    
 on 29 Oct 2025 at 20:32
  
      The MathWorks Service Host is a critical required part of the MathWorks software installed on your machine. If you encounter startup issues, uninstalling and reinstalling the MathWorks Service Host may resolve these issues. In order to reinstall the MathWorks Service Host please follow the steps below:
MathWorks Service Host Re-installer
When running the MathWorks Service Host Re-installer, ensure that you are running it as the user who will be using MATLAB.
Windows - Download and run the executable:https://www.mathworks.com/MathWorksServiceHost/win64/ReinstallMathWorksServiceHost.exe 
Mac - Download the .dmg, double-click it, double-click the app within it, and allow it to run.
Mac (Apple Silicon):https://www.mathworks.com/MathWorksServiceHost/maca64/ReinstallMathWorksServiceHost.dmg
Linux - execute these 3 commands in Terminal:
wget https://www.mathworks.com/MathWorksServiceHost/glnxa64/ReinstallMathWorksServiceHost
chmod +x ReinstallMathWorksServiceHost
./ReinstallMathWorksServiceHost
If you are accessing a Linux machine from Terminal-only without access to a display, run the executable like this:
./ReinstallMathWorksServiceHost -mode silent
Manual Re-installation: 
Note: MATLAB itself should not be uninstalled and reinstalled when performing the workflows below.
We first need to close out any MATLAB sessions; please save your work and shutdown MATLAB before proceeding.
Run the following operating system commands to end the MathWorksServiceHost process and delete its installation directories.
Windows 
Open Command Prompt by searching for it from the Windows Start menu. Then, run each of these commands one at a time: 
Taskkill /IM MathWorksServiceHost.exe /F 
rd /s /q %localappdata%\MathWorks\ServiceHost %localappdata%\MathWorks\MATLABConnector
Note: Ensure using only Command Prompt for this step to avoid errors.
macOS
Open the Terminal app by searching for it in Spotlight Search. Spotlight Search is the magnifying glass in the top-right corner of your macOS screen. Then, run each of these commands one at a time: 
killall MathWorksServiceHost 
rm -rf ~/Library/Application\ Support/MathWorks/ServiceHost ~/Library/Application\ Support/MathWorks/MATLABConnector
Linux 
Open a terminal window. The way to open a terminal window depends on your Linux distribution. Then, run each of these commands one at a time:
killall MATLAB MathWorksServiceHost 
rm -rf ~/.MathWorks/ServiceHost ~/.MATLABConnector 
To see if your issue has been resolved, try starting MATLAB. This will automatically reinstall MathWorks Service Host.
If you are still running into errors after trying the above, collect the MathWorks Service Host logs and Contact Support
To collect the MathWorks Service Host logs, refer to the following article.
More Answers (0)
See Also
Categories
				Find more on Introduction to Installation and Licensing in Help Center and File Exchange
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
