SSH Setup On Gitlab
How to add SSH key to your gitlab account?

Jay Kumar is a proficient JavaScript and Node.js developer with 7 years of experience in building dynamic and scalable web applications. With a deep understanding of modern web technologies, Jay excels at creating efficient and innovative solutions. He enjoys sharing his knowledge through blogging, helping fellow developers stay updated with the latest trends and best practices in the industry.
You can setup your gitlab account with SSH Key
Step-1:
Open Git Bash in Windows OS OR in Mac OS open Terminal
Step-2:
Run below Command (Replace your mail address)
ssh-keygen -t rsa -C "youremail@domain.com" -b 4096
It will ask few questions. You can skip it by hitting enter key.
Step-3:
Run the below command to read SSH Key
cat ~/.ssh/id_rsa.pub
Copy your SSH key until your email address.
Step-4:
- Open you gitlab Account
- Go to Settings
- Click on 'SSH Keys' (Left Bottom Side)
- Paste SSH Key
- If you want to set expiry of your SSH Key then you can set an expiry date.
- Then Click on 'Add Key' Button







