MATLAB Answers

Why do I get a connection error when installing or activating MATLAB or another MathWorks product?

12.829 views (last 30 days)
I get an error that I cannot connect to MathWorks when running the MathWorks installer or the activation client; however, I can access the website. Why can't the MathWorks Installer or activation client connect to the MathWorks?
Connection Error
The application could not connect to MathWorks.
For more information on resolving this issue, see this Support Article.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 1 Apr 2020
Edited: MathWorks Support Team on 25 Sep 2020
Computer Security software is preventing the MathWorks Installer from connecting to the MathWorks servers. This is known as a connection issue due one or more of the following:
  • Antivirus Software
  • Proxy
  • Firewall
Antivirus Software
To temporarily disable your Antivirus on Windows:
  1. Locate the Antivirus protection program icon on the Windows system tray.
  2. Right-click the icon and select Disable, Stop, etc. to temporarily disable the program. In some cases, you may need to open the program and disable it using the program's menus.
To temporarily disable your Antivirus on a Mac:
  1. Locate the Antivirus icon found on your Mac menu bar.
  2. Click Shut down or disable temporarily until installation and activation have completed.
To temporarily disable your Antivirus on a Linux:
  1. Locate the Antivirus protection program icon on the Linux system tray.
  2. Click Shut down or disable temporarily until installation and activation have completed.
Proxy
The MATLAB installer, activation client and update installer will try to automatically inherit your computer's proxy settings on Windows. If this process fails, you may need to manually enter your settings using the "connection settings" button on the first screen of the installer or activation client. The update installer will not allow you to enter your proxy credentials as it automatically inherits your computer's proxy settings. On Mac and Linux, you will always need to enter these settings manually.
To disable your Proxy in Internet Explorer:
  1. Click the Tools button and then select Internet Options.
  2. Click the Connections tab and then select LAN settings.
  3. Uncheck the check box for Use a proxy server for your LAN.
To disable your Proxy in Chrome:
  1. Open the Customize and Control Google Chrome menu by clicking on the three-dots icon at the top right of Google Chrome, select Settings on the right, find Advanced and finally select o*pen proxy settings.*
  2. Select the LAN Settings button.
  3. Deselect the checkbox for Use a proxy server for your LAN.
To disable your Proxy in Safari:
  1. Go to Menu and click on Preferences from the drop-down menu.
  2. Select the Advanced tab and then click on the Change Settings button.
  3. Deselect the checkbox for Use a proxy server for your LAN.
To disable your Proxy in Firefox:
  1. Click the Tools button and select Options.
  2. Go to the Advanced panel and select the Network tab.
  3. Click on Settings in the Connection Section and select No Proxy.
You will need to contact your IT Help Desk to troubleshoot this issue if you don't know your proxy settings or the error persists after entering your proxy settings.
Firewall
You will need to contact your IT Help Desk if your organization is running a network firewall to configure it to bypass blocked connections to the MathWorks servers.
The MathWorks installer needs to contact MathWorks servers on the following ports and addresses:
  • login.mathworks.com
  • services.mathworks.com
  • TCP ports 80 and 443
Your firewall needs to bypass blocked connections for both addresses over both ports. These servers do not use a Static IP Address and will resolve to a Dynamic IP Address. This means that users will not be able to white-list MathWorks servers via IP Address and will have to use the domain name.
If the MathWorks installer is still unable to connect after troubleshooting your proxy and firewall, submit a service request using the link below. Please include the troubleshooting steps you took to resolve the connection issue, and include your installation log file. See this related article if you need assistance locating your log file:

  33 Comments

Andrea Silvestro
Andrea Silvestro on 18 May 2020
MARIO CHANG could you help me? I do not understand your explanation. What is the installation folder? I do not have access to another Mac.

Sign in to comment.

More Answers (48)

Sean
Sean on 30 Jul 2014
When I received this error, it was not due to proxy settings or firewall settings. Rather, when I downloaded the installer, the download location was on a remote drive (a windows remote profile DFS location). I copied the setup file to the local drive, and it ran fine.

  12 Comments

Show 9 older comments
Walter Roberson
Walter Roberson on 24 Jan 2020
Which drive are you asking about, Rojitha Goonesekere ?
Try looking in ~/Downloads/MathWorks/R2019b/ perhaps? That is where the installer tosses the installation program and archives .
Tong Li
Tong Li on 16 Apr 2020
It is so useful!!! I change the download files location from 'download' to 'program files/matlab' and it installed successful!!!

Sign in to comment.


khalid Houhou
khalid Houhou on 28 Feb 2018
I had this issue and it was not related to any network or connection. It was caused by a Malware I had in my PC called relevantknowledge. I uninstall it and it worked.

  10 Comments

Show 7 older comments

Sign in to comment.


Brett Hansell
Brett Hansell on 8 Oct 2019
  1. Under System Variables, select New.
  2. Set the first variable name "JAVA_TOOL_OPTIONS" with the value of "-Djava.net.preferIPv4Stack=true" (enter these without the quotation marks)
  3. select New again.
  4. Set the second variable name "JAVA_OPTIONS" with the value of "-Djava.net.preferIPv4Stack=true" (enter these without the quotation marks) and click on OK
  5. Click OK again on the previous screen and try the installer again.

  9 Comments

Show 6 older comments

Sign in to comment.


Brian Zarling
Brian Zarling on 16 Feb 2015
I turned off my firewall and I still can't connect to Mathworks.

  6 Comments

Show 3 older comments
Daniel Torres
Daniel Torres on 26 Aug 2020
I was getting installation errors left and right. I did an internet speed test and saw I was pulling only 10MB. I relocated my wireless dongle, retested, 150MB. Tried again - installed successfully.
Seems the installer is persnickity with your download speeds.

Sign in to comment.


Chris Håkansson
Chris Håkansson on 23 Feb 2015
I had the same problem and followed all instructions above about filling in proxy-server information and deactivating the firewall etc. but nothing worked. Turned out all I needed to do was uncheck the box which indicates to use a proxy server. It is as mentioned in other links found in Control Panel/Internet Options/Connections/Lan Settings.

  4 Comments

Show 1 older comment

Sign in to comment.


Caitlyn Hampel
Caitlyn Hampel on 24 May 2015
I had this problem as well, but I found that it was because my internet connection was too slow. So it only worked when I used a faster connection. Beware that the downloads during installation are rather large files, including the toolbox add-ons. Hope this information can be of help to others.

  2 Comments

Mark Hulley
Mark Hulley on 9 Jun 2016
I had the same issue but it must have been my connection speed, because it worked on the third attempt without me actually changing anything.

Sign in to comment.


Gregg Casey
Gregg Casey on 29 Dec 2017
Had the same problem on my Mac and I have never had a problem like this on a Mac since I have used them. (Probably more than 8 years.) My laptop did not have the firewall turned on at all during all attempts. So this is probably just badly written software from Mathworks. What worked for me is to use my hotspot. That is all I changed - connect to my Karma hotspot and click "Next" again. Done. Note that I first did the same after connecting to my iPhone as a hotspot and that did not work. (Just clicked "next" and got the same error message.) However, that could have been that my phone was having a connection issue.
Mathworks- please look into this issue and fix it. The software should not require special proxy settings.

  3 Comments

jinxxx
jinxxx on 3 May 2018
Me too, maybe you should try it for a couple more times. I only successfully installed it after 10 times, but I made it at last.
Kyle Perry
Kyle Perry on 12 Dec 2018
Hello Ben,
If you are unable to activate successfully through your hotspot, you can try to activate MATLAB through the manual method. I have attached a link below that explins this process:

Sign in to comment.


Jon
Jon on 16 Dec 2014
On a Mac (running 10.10 [Yosemite]) I still needed to temporarily disable the Firewall (under System Preferences > Security & Privacy) in order to complete activation.

Donald Niman
Donald Niman on 23 Feb 2015
This is what I did to successfully install Matlab (Home Use) on my Windows 7 x64 SP1 system. Note that I do not know which one of the following things helped to make things work; I just did all of them. Also note that I am not using a proxy server, if you are, this will probably not help you.
1. Turned off internet router and then turned it back on.
2. Restarted the PC in Safe Mode.
3. If applicable to you: The installation file was on hard drive volume D:\ and I moved it to C:\
4. From control panel->administrative tools->Services, I right-clicked "Windows Firewall" and selected "Stop".
5. I ran the Matlab installation file from c:\.
6. When the installation screen came up, I did not click on the button at the top right of the dialog. Instead, I clicked the "next" button at the bottom. (Of course, I am not using a proxy server.)
7. A dialog appears to enter your login credentials: do that and the installation will continue.
8. The installation will eventually complete and then you can activate it by following the on-screen directions.
9. I restarted the system normally and verified that Matlab was working.
(Hopefully, I did not leave anything out.)

  4 Comments

Show 1 older comment

Sign in to comment.


Anna Smirnova
Anna Smirnova on 1 Jul 2018
Error : unable to connect to host. sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
Windows 7 64-bit. What am I doing wrong?

  0 Comments

Sign in to comment.


Matthias Finsterbusch
Matthias Finsterbusch on 2 Jul 2018
I am trying to install Matlab 2018b on a Win10 64bit System, getting the following error:
"Error : unable to connect to host. sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target"
Any instructions how to handle this problem? Thanks in advance.

Jan
Jan on 14 Mar 2019
Create the two environment variables
  • "JAVA_TOOL_OPTIONS" with the value "-Djava.net.preferIPv4Stack=true"
  • "JAVA_OPTIONS" with the value "-Djava.net.preferIPv4Stack=true"
Run the installer. Afterwards the variables can be removed.

  3 Comments

XiaoQian Ye
XiaoQian Ye on 29 Nov 2019
Also did the trick for me. Thanks. (After tried Firewall, antivirus, proxy all off). Mind giving a headup what the paramenters did? Thanks again!
Ani Padma
Ani Padma on 11 Jul 2020

Thanks a lot Jan, I tried all other suggested solutions with no success...I was even considering upgrading my laptop to a new one thinking it might be a hardware issue.However, this environment variables solution worked for me...Phew!!

Sign in to comment.


Yehya Jebbaoui
Yehya Jebbaoui on 28 Sep 2017
Turn off the Wifi of the institution you are in, then turn on Mobile hotspot on your phone to share the mobile connection (if you have 3G or 4G). You will pass the first steps and it will start downloading. When it starts downloading, switch to the wifi. It worked for me.

Dewi Mar'a
Dewi Mar'a on 20 Nov 2018
I am dealing with the same problem. After almost a week I tried to install matlab more than hundred times, then I got no solution at all. My windows firewall was off, no proxy setting, no anti virus installed, even no matlab installed yet.
I am getting deperate with this problem because my deadline project comes closer, and I wasted the time too much to deal with this problem.
finally I end up with the last solution left, I tried to uninstall my windows, and try to install matlab again. BAAAAMMM....it works. do anything to get out of this stuck step. if it ends with great result, why not ? haha

  1 Comment

lin hv
lin hv on 16 Aug 2019
I feel so sorry about that. I am still through this annoying problem, yet I have to spend my time on those matter more.

Sign in to comment.


Jiawei Meng
Jiawei Meng on 15 May 2020
Guys, I just tried 16 times....Yes, I counted it and now it works. So don't give up....
However, I don't whether it is because my internet connection is bad or not? Because I literally changed nothing....

Luke
Luke on 26 Nov 2014
Edited: Luke on 26 Nov 2014
Internet security software designed to block certain IP ranges such as PeerBlock have MathWorks black listed in the default block-list.
Just set the blocked IP to "allow permanently" to let the installer connect and download your license details, software and associated toolboxes.

  1 Comment

Walter Roberson
Walter Roberson on 16 Jan 2017
Mathworks delivers some of its content using one of the major cloud providers. It might be the case that the cloud provider is what is blacklisted rather than Mathworks itself.

Sign in to comment.


Carsten Jorgensen
Carsten Jorgensen on 15 Jul 2015
I just came across this same error. At first, I assumed it was because I was installing on a Windows XP system. When I discovered that Win XP was still supported for 2015a, I decided to troubleshoot further.
My resolution: The system could not communicate with the MatLab servers because the Date/Time on the system was inaccurate. - Setting the systems Date/Time correctly resolved the issue.

  0 Comments

Sign in to comment.


Tony Langley
Tony Langley on 5 Dec 2015
I recently faced the same issue on my Mac. It wasn't because I was using a network proxy (per se) or that the I had OSX's firewall turned on.
Eventually I worked out that it was because of Kaspersky Internet Security. So I temporarily disabled that which then allowed the installer to work.

  3 Comments

Günther Wal
Günther Wal on 12 Jan 2016
I had the same prob on my mac. I discovered that I have to open it in the same network as I installed the software. Support didn´t provide any help. For me it´s over and out, I stick with Mathematica...
aMusings
aMusings on 30 Jan 2016
Having this issue on a Mac with El Capitan. Confirmed with Network Utility that we could reach both ports 80 and 443 at both urls listed above. Firewalls were turned off on both individual machine and router. Suggestions?

Sign in to comment.


Daniel
Daniel on 26 Oct 2017
The buttons on the window "Mathworks Software Activation" are even broken now. All that work for nothing. Why are there always major issues with installations from Mathworks?


ramesh
ramesh on 21 Nov 2018
The ``Accepted Solution" does not work for linux.
Issue: Trying to install matlab using the downloaded installer. At the ``Folder Selection" step, now infamous error, ``Connection Error" is thrown.
The system:
  1. Doesn't have Antivirus Software
  2. Doesn't have a proxy
  3. Has Firewall service stopped
However, the installer still isn't moving forward. Needless to say, every other website/service connection works.
I am more inclined to think that the problem lies on the mathworks side rather than the users' side. Before this error, I had an unsuccessful installation due to my machine freezing. I am not sure why anyone would blacklist mathworks.com. TCP port 80, I believe, is for http, and I'm not sure how anyone would be able to browse any website with that port closed. Yet one of the steps of the solution is to open that port. My suggestion is to separate the operating system and not lump solutions together. Clearly, matlab behaves differently in different systems, e.g. the proxy settings.

  2 Comments

ramesh
ramesh on 21 Nov 2018
Update:
Tried one last time before quitting and now the installer is moving along. I even had the firewall restarted. I guess the best solution is to continue trying as few have mentioned. Maybe mathworks needs to look at it further.

Sign in to comment.


ismail tepedag
ismail tepedag on 14 Jan 2019
Hey guys, I read everything and closed antivirus , firewall etc...
Then it did not work.
I tried repeatedly some 10 times then it worked miracleously. ?!
As a result, try try try...

  0 Comments

Sign in to comment.


James Van Zandt
James Van Zandt on 1 Feb 2019
Edited: James Van Zandt on 1 Feb 2019
The above installation instructions claim that the proxy information must always be entered manually on a Mac, but the following instructions only address disabling proxy settings in browsers. None of the browsers seem to be using during installation, so their settings need not be changed. It's only necessary to discover how to configure the installer.
I navigated Apple -> System Preferences -> Network -> Advanced -> Proxies, and found it was set for "Automatic Proxy Configuration", with a URL for a proxy configuration file. Inspecting that file, I found the appropriate proxy server. It didn't mention a port number, but I guessed "80".
In the “MathWorks Installer” window, I hit “Connection Settings” (not actually mentioned in the instructions). I filled in the server and port, and left name and password fields blank. That worked.

  0 Comments

Sign in to comment.


august winkelman
august winkelman on 2 Mar 2019
In my case (Ubuntu 18.04.02), R2018b installed nicely but activation only worked after a second trial. Not a big deal but if I remember well that was the same 2 years ago with R2016... Might be because the connection was idle a long time between installation and activation.

krishna teja medam
krishna teja medam on 14 Apr 2019
I am using MacOS Mojave 10.14.4. I tried using my firewall turned off but it didn't work. I get "remote host closed connection during Handshake" error always I clicked install. With the firewall turned off, I restarted my system and tried to install again. This time it worked. Hope this solution might help anyone out there.

  1 Comment

Sign in to comment.


ZAZHIL-HA HERENA
ZAZHIL-HA HERENA on 3 Jun 2019
Hi,
I had the same problem 4402 when trying to start matlab and turned out that my trial license had expired, I requested for a new trial version and I got it. You may check the status of your license at: https://www.mathworks.com/licensecenter/trials
Zazhil-ha

  0 Comments

Sign in to comment.




Alexei Jolkin
Alexei Jolkin on 22 Nov 2019
Edited: Alexei Jolkin on 6 Dec 2019
Connection Error
" The application could not connect to MathWorks."
As many other Matlab users I am on a corporate network with lots of cooky stuff which I have no control of whatsoever. I've wasted a day tweaking Proxy, Firewall and Java (Antivirus is absolutely out of my control). Still could not install Matlab, NO MATTER if I use Wi-Fi or wired connection.
However I could instal Matlab AFTER uninstalling a program named ZScaler and all of it instances from the "Apps & Features" dialog (Add or remove programs system setting). This miserable ZScaler is a part of some sort of corporate cloud solution and messes things up pretty badly.
Ripp this ZScaler off your computer and you will be able to install Matlab. All my cloud drives still work, at least in te office area. I am on W10.
Good luck!

  0 Comments

Sign in to comment.


Alejandro Ayala
Alejandro Ayala on 5 Dec 2019
I had the same issue multiple times and it was simply a connectivity issue, whenever I used WiFi to try and download the software it would get the the very end and display an error, but when I connected my laptop via Ethernet it downloaded much faster and did end up completing the download. Also make sure when you download Matlab, that all the software you need is being downloaded as well!

  2 Comments

Anshita Dhoot
Anshita Dhoot on 25 Dec 2019
to download it, is it compulsory to get connected via ethernet not wifi?
Connection Error
The application could not connect to MathWorks.
For more information on resolving this issue, see this Support Article.
Walter Roberson
Walter Roberson on 25 Dec 2019
WiFi can be used. However, a full version of MATLAB can be more than 15 gigabytes, so it might not be practical to use WiFi if you have a lot of toolboxes -- too much time and too much chance that the WiFi connection might get interrupted (for example using a microwave oven can disrupt WiFi)

Sign in to comment.


tong zhang
tong zhang on 8 Jan 2020
After i clicked the setup program, i got the note that i can not get connected to Mathworks. But a file named "_temp_matlab_R2019b_win64" is added and in this file, there is a program named "setup". Click it and you will find it works!

Tamás Túri
Tamás Túri on 24 Jan 2020
Edited: Tamás Túri on 24 Jan 2020
Please give a more clear explanation and solution. I had ro reinstall my laptop, before in around September the installation was seamless. Now none of the above solutions are actually working and I just do not understand a professional software company how can issue a not working installer.

  3 Comments

Tamás Túri
Tamás Túri on 24 Jan 2020
All the above is misleanding. One comment contains the real solution, there is a mailware called "relevantknowledge" which prevents the connection! I have no idea how this appeared on my computer. I removed this program called, "relevantknowledge", and now it works.

Sign in to comment.


Arpan Sharma
Arpan Sharma on 10 Feb 2020
Edited: Arpan Sharma on 10 Feb 2020
just disconnect with your organisation wifi and proceed with your mobile hotspot till download. When download starts, switch to your organisation wifi. It worked for me

  0 Comments

Sign in to comment.