IPython Notebook

IPython Notebook has two sets of keyboard shorcuts. Edit mode is active when the cursor is in a cell and the cell has a green border. Command mode is active when the cell has a grey border and the editing cursor is not inside any cell.

Active in Both Modes

CTRL+Enter

Run cell

SHIFT+Enter

Run cell and select cell below

OPTION+Enter

Run cell and insert new cell below

CMD+S

CTRL+S

Save notebook

Edit Mode

Esc

CTRL+M

Command mode

OPTION+"-"

Split Cell

Command Mode

Enter

Go to edit mode

Y

Switch cell to code mode

M

Switch cell to Markdown/LaTeX mode

1..6

Switch cell to Heading of respective level (1-6)

Arrow Up

K

Go to cell above

Arrow Down

J

Go to cell below

CTRL+K

Move cell up

CTRL+J

Move cell down

SHIFT+Arrow Up

SHIFT+K

Extend selection up

SHIFT+Arrow Down

SHIFT+J

Extend selection down

A

Insert cell above

B

Insert cell below

X

Cut cell

C

Copy cell

V

Paste cell below

D D

Delete Cell

Press twice

Z

Undo delete

CTRL+SHIFT+-

Split cell at cursor

SHIFT+=

Merge with cell below

SHIFT+M

Merge selected cells

L

Toggle line numbers

SHIFT+L

Toggle all cell line numbers

O

SHIFT+O

Toggle output

Kernel

I

Interrupt kernel

.

Restart kernel

Inspector

CTRL+I

Open in new tab