Download R Tools
-->
The program is included in Development Tools. Our antivirus scan shows that this download is malware free. Rtools is developed for Windows XP/Vista/7/8/10 environment, 32 and 64-bit versions. The program's installer files are generally known as McDonalds.RTools.Offline.exe, msys2.exe, OTMClient.exe, OTMLancher.exe or RTools.exe etc. Find R-tools Technology software downloads at CNET Download.com, the most comprehensive source for safe, trusted, and spyware-free downloads on the Web.
In this article:
Note
After installing R Tools, you may want to configure Visual Studio for an optimized data scientist layout, as described on the Options article.
Supported versions of Visual Studio
R Tools for Visual Studio (RTVS) is supported on Windows with the Community (free), Professional, and Enterprise editions of both Visual Studio 2017 and Visual Studio 2015 Update 3 (or higher) (direct download).
RTVS is not presently supported on Visual Studio for Mac.
RTVS does not install if you have only the Visual Studio Shell that's included with products such as Visual Studio Test Professional and SQL Server Management Studio. Visual Studio Shell lacks the necessary components for RTVS.
Install RTVS in Visual Studio 2017
Run the Visual Studio installer and select the Modify option (for details, see Modify Visual Studio). If you don't yet have Visual Studio installed, see Install Visual Studio. On Windows 7, be sure that your installer is updated to show Visual Studio 2017 version 15.2 build 26430.12 or later.
Select the Data science and analytical applications workload:
Set any additional options on the right side under the same workload name. By default, this workload includes F# and Python support. For R, minimum requirements are R language support, Runtime support for R development, and Microsoft R client.
RTVS is installed in: %ProgramFiles(x86)%Microsoft Visual Studio<version><edition>Common7IDEExtensionsMicrosoftR Tools for Visual Studio where <version> is typically 2017
and <edition> is Community
, Professional
, or Enterprise
.
Install RTVS in Visual Studio 2015
With Visual Studio 2015, you need to install an R interpreter and the R Tools separately.
Download R Tools Mac
Install an R interpreter
RTVS requires a 64-bit installation of R version 3.2.1 or higher from one or more of the following sources:
Microsoft R Open and CRAN R both allow for multiple side-by-side versions. Microsoft R Client, however, supports only one version and always uses the latest one you installed.
Install the R tools
Download the current RTVS for Visual Studio 2015 from https://rtvs.blob.core.windows.net/download/RTVS_2017-12-18.1.exe. RTVS checks for a suitable version of Visual Studio and helps you install an R interpreter if you haven't already.
Note
The standalone RTVS installer works only with Visual Studio 2015; with Visual Studio 2017, install R support through the Data Science and Analytical Applications workload as described earlier.
RTVS for Visual Studio 2015 is installed in: %ProgramFiles(x86)%Microsoft Visual Studio 14Common7IDEExtensionsMicrosoftR Tools for Visual Studio
Offline installation of Visual Studio and RTVS
Offline installation is suitable for computers that are not connected to the Internet:
Go to Create an offline installation of Visual Studio 2017.
If you use Visual Studio 2015, select 2015 in the selector above the table of contents.
Follow the instructions for creating an offline installation in the web page.
For Visual Studio 2015, download the offline RTVS installers from https://rtvs.blob.core.windows.net/download/RTVS_2017-12-18.1.zip and https://rtvs.blob.core.windows.net/download/RTVS_Remote_2017-12-12.1.zip.
Install Visual Studio and RTVS from the offline installers.
See also
Starting with R 4.0.0 (released April 2020), R for Windows uses a toolchain bundle called rtools40.
This version of Rtools includes gcc 8.3.0, and introduces a new build system based on msys2, which makes easier to build and maintain R itself as well as the system libraries needed by R packages on Windows. Recent builds of rtools40 also contain an additional gcc-10 ucrt toolchain for testing R packages and system libraries with the experimental ucrt builds of R-devel. For more information about these topics, follow the links at the bottom of this document.
Download R Tools
The current version of Rtools is maintained by Jeroen Ooms. Older editions were put together by Prof. Brian Ripley and Duncan Murdoch. The best place for reporting bugs is via the r-windows organization on GitHub.
Installing Rtools40
Note that rtools40 is only needed build R packages with C/C++/Fortran code from source. By default, R for Windows installs the precompiled “binary packages” from CRAN, for which you do not need rtools!
Download R Tools For Windows 10
To use rtools40, download the installer from CRAN:
- On Windows 64-bit: rtools40v2-x86_64.exe (recommended: includes i386, x64, and x64-ucrt compilers)
- On Windows 32-bit: rtools40-i686.exe (i386 compilers only)
Note for RStudio users: please check you are using a recent version of RStudio (at least 1.2.5042
) to work with rtools40.
Putting Rtools on the PATH
After installation is complete, you need to perform one more step to be able to compile R packages: you need to put the location of the Rtools make utilities (bash
, make
, etc) on the PATH
. The easiest way to do so is create a text file .Renviron
in your Documents folder which contains the following line:
You can do this with a text editor, or from R like so (note that in R code you need to escape backslashes):
Now restart R, and verify that make
can be found, which should show the path to your Rtools installation.
If this works, you can try to install an R package from source:
If this succeeds, you’re good to go! See the links below to learn more about rtools40 and the Windows build infrastructure.
Further Documentation
More documentation about using rtools40 for R users and package authors:
Download R Tools For Visual Studio
- Using pacman: the new rtools package manager to build and install C/C++ system libraries.
- Installing R packages: Some older R packages that need extra help to compile.
- Testing packages with ucrt64: Instructions for building and testing using the experimental UCRT toolchains.
- FAQ: Common questions about Rtools40 and R on Windows.
Download R Tools For R Studio
Advanced information about building R base and building system libraries:
Download Rtools Zip
- r-base: Scripts for building R for Windows using rtools40.
- rtools-packages: Toolchains and static libraries for rtools40 (GCC 8+)
- rtools-backports: Backported C/C++ libraries for the gcc-4.9.3 legacy toolchain (for R 3.3 - 3.6)
- rtools-installer: Builds the rtools40 installer bundle.