A Facebook clone built with the MERN stack.
- PLEASE NOTE: The app is hosted on a free tier, so it may take up to 30 seconds to load
TEST USER: username:
john
, password:1234
https://facebook-mern.onrender.com/
NOTE: Some test users are:
username: john
password: 1234
username: kate
password: 1234
- Clone the repo and
cd
into the project directory - Add a .env file in the root directory with the following variables:
MONGO_URI='YOUR_MONGODB_URI'
SECRET='ANY_SECRET_KEY'
PORT=4000
NODE_ENV='development'
- RUN SERVER:
npm install
npm start
- RUN CLIENT (open a new terminal window):
cd client
npm install
npm start
- Open http://localhost:3000 to view it in the browser.
NOTE: The server will also serve the build folder on http://localhost:4000 if you set the NODE_ENV
variable to production
.