MATLAB Answers

Why have all my MAT-files become associated with Microsoft Access?

363 views (last 30 days)
Whenever I open a MAT-file outside of MATLAB, it opens with Microsoft Access. I would like to associate MAT-files with MATLAB.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 9 Mar 2018
Edited: MathWorks Support Team on 9 Mar 2018
Information relevant to this issue has been incorporated into the documentation as of Release 2013a (R2013a). For previous releases, read below for any additional information:
This behavior occurs after installing Microsoft Office. The .mat extension becomes associated with Microsoft Access if you do not deselect this option during Access installation.
Microsoft Office causes the *.mat files to appear as shortcuts and not as actual files to Windows.
If you are using Microsoft Windows 10, you can restore the file associations with the following steps:
1. Open 'Control Panel'. This can be done by right click on the windows icon on the bottom left corner of your screen then select 'Control Panel'
2. In the ‘Control Panel’, click on 'Programs' section, then on the next page, under the 'Default Programs', click on 'Make a file type always open in a specific program'
3. In the next page, you will see a list of file extensions with their associated default programs. Find the MAT file then click 'Change program' button at the top right corner
4. There will be a pop-up menu where you can select to associate the MAT file with MATLAB
If you are using Microsoft Windows Vista or 7, you can restore the file associations with the following steps:
1. Click the Windows Start menu.
2. Select Control Panel.
3a. If the Control Panel view is set to "View by: Category" in the top right, navigate to: Programs > Default Programs >Associate a file type or protocol with a program
OR
3b. If the Control Panel view is set to "View by: Small icons" or "View by: Large icons" in the top right, navigate to:  Default Programs >Associate a file type or protocol with a program
4. After the Set Associations window populates, scroll down to the .mat option.
5. Click it, and then click on "Change Program" on the top right corner.
6. Select MATLAB. If MATLAB is not listed in the program list, click on "Browse" then search for the MATLAB application, which is located in the MATLABROOT folder. On a Windows machine, this is usually C:\Program Files\MATLAB\R20* where R20* is the version of MATLAB.
7. Click Close to close the Set Associations window.
8. All MAT files will now open with MATLAB.
If you are using MATLAB on Microsoft Windows XP, read below for instructions:
1. From a Windows Explorer window, select "Tools -> Folder Options -> File Types".
2. Now select 'New'.
3. Enter the MAT extension in the text box.
4. Click 'Advanced' and from the List Box select 'MATLAB data file' or 'MATLAB MAT-file'.
5. After making this change, you will be able to use the "Change" button on the File Types dialog to make further changes such as selecting a specific MATLAB release.
or follow the instructions from the following link:

  5 Comments

Show 2 older comments
Bryan Wilson
Bryan Wilson on 11 Sep 2018
I am having a similar problem using Windows 10. Though when I browse to the MatLab.exe file to change the association, nothing changes. It's still stuck on Access.
Image Analyst
Image Analyst on 1 Aug 2019
Note that the Mathworks Support Team answer for Windows 10 does not work. For example, there is no Programs in Control Panel. I see a differently-named sequence of steps. Nor is there any "Open with..." option that some people meantioned. What you need to do is:
  1. Left-click the Start button and left-click the gear to bring up Control Panel.
  2. Left-click on the Apps icon (not Programs, which doesn't exist on my computer)
  3. On the left hand panel, left-click "Default apps"
  4. Scroll down a bit past some icons and click on the blue text "Choose default apps by file type"
  5. If you're lucky, you'll see something like FIgure 1 below. In that case click on the Access icon and then select MATLAB from the list of apps that appears. If you're not lucky, then you'll see figure 2 below and you will have no opportunity to select MATLAB.
------------------------------------------------------------------------------------
FIGURE 1
capture1.png
------------------------------------------------------------------------------------
FIGURE 2
Capture.PNG
Note: Figure 2 is from a computer that has had the MATLAB Runtime Library installed (MCRInstaller.exe), but not the MATLAB development environment.
Nima Zamani
Nima Zamani on 20 Oct 2019
I had the same problem and there was no MATLAB option in the default program menu. To solve this, try to rename the *mat file (you don't see the extension) and put an extension in the name - I renamed it to test.mat. after renaming, when you double click on the file or right click, now you have the option to choose another program. Matlab.exe is the .../MATLAB/bin folder. when you are done, the extensions appear and the icon changes to matlab icon. Now you'll see test.mat.mat whcich you can rename it again and delete the last .mat.

Sign in to comment.

More Answers (5)

MMBB
MMBB on 6 Feb 2018
I am having the same problem. My .mat files are associated with Access which I can't uninstall as it's part of the Microsoft package (I'm using a lab computer). Matlab is not recognized in the default apps section (only options are Access or something from the App store) as it is a third party program. There is no 'open with' option on the .mat files but even if there was, I have no idea which folder I am to navigate to (when I go to C:\Program Files\MATLAB\R2017b, I don't know what to choose). Any help would be greatly appreciated!!!!

  2 Comments

NAVATHA SAI
NAVATHA SAI on 29 Mar 2018
i am also suffering from the same problem.. we dont have a change program option also.. then how to change the default app !!
Kendall Copp
Kendall Copp on 13 Jul 2018
Hey MMRB and NAVTHA SAI, I don't know if you're still looking for a solution, but I have made a little progress. See my comment on Mathworks Support Team's answer above.
Edit: direct link to my comment: https://www.mathworks.com/matlabcentral/answers/103000-why-have-all-my-mat-files-become-associated-with-microsoft-access#comment_589163

Sign in to comment.


Abdelrazzaq
Abdelrazzaq on 1 Apr 2014
What about the "crazy" windows 8

  0 Comments

Sign in to comment.


Jelena Ponocko
Jelena Ponocko on 30 Jun 2016
For Miscrosoft Office 2010, after you open your folder with access files, select one of them and just click on the arrow next to Microsoft Access icon on the top and choose Matlab as the default program - worked for me.

  0 Comments

Sign in to comment.


Al in St. Louis
Al in St. Louis on 19 Nov 2018
I have Office 365 and Windows 7. I've reset my default program to MATLAB a few days ago, but Office hijacked the .MAT files again. I have to assume this occurs during an Office Update installation.

  0 Comments

Sign in to comment.


Manar Tamimi
Manar Tamimi on 13 Feb 2019
Thanks MathWorks support time.
Solved.

  0 Comments

Sign in to comment.

Sign in to answer this question.