DEV Community

Chillar Anand
Chillar Anand

Posted on • Originally published at avilpage.com on

Setup FTP server on Mac OS X

On Linux & Mac OS X, Python comes pre-installed. On Windows, we can install it from Windows store or from https://python.org website.

We can verify the Python version using the below command.

$ python --version
Python 3.11.6

Enter fullscreen mode Exit fullscreen mode

We can use the pyftpdlib library to create an FTP server. We can install the library using the below command.

$ python -m pip install pyftpdlib
[I 11:28:21] concurrency model: async
[I 11:28:21] masquerade (NAT) address: None
[I 11:28:21] passive ports: None
[I 11:28:21] >>> starting FTP server on :::2121, pid=99951 <<<

Enter fullscreen mode Exit fullscreen mode

Now, we can start the FTP server using the below command.

$ python -m pyftpdlib

Enter fullscreen mode Exit fullscreen mode

It will start the FTP server on port 2121. We can connect to the FTP server using the below command.

$ ftp localhost 2121

Enter fullscreen mode Exit fullscreen mode

Top comments (0)