edit on Repl.it

Editor Tips and Tricks

The following “Tips and Tricks” will teach you how to be productive in Repl.it code editor. Here, you will become familiar with the code editor’s powerful shortcuts for editing, writing, and inspecting code.

Command Palette

The command palette allows you to view all available commands based on your current context.

To access the command palette on a Mac, press shift+cmd+P. On other computers, press ctrl+shift+P.

command palette

Frequently Used Keyboard Shortcuts

The following keyboard shortcuts can be used in a variety of ways. If you forget a keyboard shortcut, check the command palette.

Moving the Current Line

Press option+up or option+down on a Mac to move the current line up or down.

On other computers, press alt+up or alt+down.

move line

Copying the Current Line

Press shift+option+up or shift+option+down on a Mac to copy the current line above or below.

On other computers, press shift+alt+up or shift+alt+down.

clone line

Selecting Lines

Press cmd+I on a Mac to select a line.

On other computers, press ctrl+I.

select line

Deleting Lines

Press shift+cmd+K on a Mac to delete a line.

On other computers, press ctrl+shift+K.

delete line

Inserting Lines

On a Mac, press shift+cmd+enter to insert a line above.

On other computers, press ctrl+shift+enter.

insert line

Adding Cursors

Press cmd+option+up or cmd+option+down on a Mac to add cursors above or below your current line.

On other computers, press ctrl+alt+up or ctrl+alt+down.

adding cursors

Find

Press cmd+F on a Mac to find.

On other computers, press ctrl+F.

find

Replace

Press option+cmd+F on a Mac to replace.

On other computers, press ctrl+H.

replace

Find Next/Previous

On a Mac, press cmd+G to find next or shift+cmd+G to find previous.

On other computers, press F3 to find next or shift+F3 to find previous.

find next

Adding Selections to Next Find Match

Press cmd+D on a Mac to add a selection to the next find match.

On other computers, press ctrl+D.

adding selections

Use the following shortcuts to navigate the editor.

Open files

Press cmd+P on a Mac to quickly open files.

On other computers, press ctrl+P.

Open files

Go to Line

Press cmd+G on a Mac to go to a specified line.

On other computers, press ctrl+G.

go to line