Emacs: Show Cursor Position

By Xah Lee. Date: . Last updated: .

Show Cursor Column Number

emacs column number mode 56206
Alt+x column-number-mode

Alt+x column-number-mode → show line number and cursor column position in mode line (aka status bar), like this: (166,3). The first is line number, the second is position from the beginning of line.

To always have it on, put the following code in your emacs init file.

;; show cursor position within line
(column-number-mode 1)

Show Ruler

Alt+x ruler-mode → display a ruler at top of current window.

emacs ruler mode 2016 12 31
Emacs Alt+x ruler-mode

Cursor Position in Buffer

Alt+x describe-char → show the current cursor position.

In a buffer, the left of first character has position 0.

emacs describe char 2018 03 01 93728
emacs Alt+x describe-char

Jump to a Cursor Position

Alt+x goto-char → move cursor to a given position.

Emacs Show Line/Column Number

  1. Show Line Numbers
  2. Show Cursor Position
  3. Save Cursor Position

Emacs Customization

  1. Emacs init file
  2. What's Major Mode
  3. What's Minor Mode
  4. M-x customize
  5. Organize Init File
  6. Byte Compile Elisp
  7. What's Hook
  8. Avoid Lambda in Hook
  9. Environment Variables in Emacs
  10. Check OS, Version, Host Name
  11. Check Defined/Loaded


  1. Install Packages
  2. Install Package Manually

text editing

  1. Define Keys
  2. Tabs, Space, Indentation Setup
  3. Brackets electric-pair-mode
  4. Isearch space for - _
  5. Ido Completion
  6. Icomplete Completion
  7. Move Cursor by camelCase
  8. Stop Cursor Going into Minibuffer Prompt
  9. Sync Clipboard with Linux X11


  1. Default Major Mode
  2. Auto Backup Off
  3. Auto Save
  4. Restore Opened Files
  5. Save Cursor Position
  6. Dired Customization
  7. Open Recently Opened


  1. Show Line Numbers
  2. Show Cursor Position
  3. Visual Line Mode, Wrap Lines
  4. High Light Current Line
  5. Font Setup
  6. Show Formfeed ^L as Line
  7. Line Spacing
  8. Set Color Theme
  9. Highlight Brackets ()[]{}
  10. Show lambda as λ
  11. Color CSS Hex Code
  12. Default Window Size


  1. Default Browser
  2. Misc Init Tips

If you have a question, put $5 at patreon and message me.
Or Buy Xah Emacs Tutorial
Or buy a nice keyboard: Best Keyboards for Emacs


Emacs Lisp