This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.


Identify current folder


currentFolder = pwd


pwd displays the MATLAB® current folder.


currentFolder = pwd returns the path to the current folder.


Store Path to MATLAB® Current Folder

Change the current folder to a local folder and store the path.

cd c:\myMATLABFiles
currentFolder = pwd
currentFolder =


Alternative Functionality

View the current folder in the Current Folder toolbar.

Output Arguments

collapse all

MATLAB current folder path, returned as a character vector.

See Also


Introduced before R2006a