Clear Screen shortcut macOS Terminal


You must be familiar with clear command to clear the text on the Terminal screen on macOS, do you know there is a keyboard shortcut as well to the same operation.

How to clear screen of Terminal using Keyboard?

Press Command + L - this will clear the console.

Note: Unlike clear command they keyboard shortcut clears one command at a time. It will not clear the whole screen.

Example:
code2care@mac ~ % pwd
/Users/code2care

code2care@mac ~ % who
code2care console  Jun 14 12:20 
code2care ttys000  Jun 27 14:20 

code2care@mac ~ % date
Sun Jun 27 14:24:22 GMT 2021

code2care@mac ~ % 

Press: Command + L

code2care@mac ~ % pwd
/Users/code2care

code2care@mac ~ % who
code2care console  Jun 14 12:20 
code2care ttys000  Jun 27 14:20 

code2care@mac ~ % 

Press: Command + L

code2care@mac ~ % pwd
/Users/code2care

code2care@mac ~ % 

Press: Command + L

code2care@mac ~ %
macOS Terminal Clear Screen using Keyboard Command and L Keys
macOS Terminal Clear Screen using Keyboard Command and L Keys


Have Questions? Post them here!



Recent Posts:




Code2care is an initiative to publish and share varied knowledge in programming and technical areas gathered during day-to-day learnings and development activities.

Students and Software Developers can leverage this portal to find solutions to their various queries without re-inventing the wheel by referring to our easy to understand posts. Technical posts might include Learnings, Video Tutorials, Code Snippets, How Tos, Blogs, Articles, etc.