% emacs -q
(scroll-bar-mode 0)
(fringe-mode 0)

there is still a pixel-wide line separating the two windows. What is this line called, and how can I change its width and colour? Can I replace it with a character such as |, as is used in the terminal?

4 Answers 4


What you want to change is called the right-divider. By default you'll just see a vertical line.

Whether the right divider is shown or not is controlled by a frame-parameter called window-divider, which you can change by evaluating


You can call M-xcustomize-variable for window-divider-default-right-width to change the default size, and M-xcustomize-face for window-divider to change its colour. Note that changing the face will also affect the bottom-divider appearance.

  • customizing window-divider didn't do anything
    – Toothrot
    Commented Jul 18, 2018 at 13:16
  • I missed out the (window-divider-mode) step. Answer corrected
    – rpluim
    Commented Jul 18, 2018 at 13:46
  • 2
    There is still a line there without window-divider-mode. That's the line I'm talking about.
    – Toothrot
    Commented Jul 18, 2018 at 14:12
  • 1
    If you turn off the fringe, via M-x customize-variable fringe-mode, and then customize the variables window-divider to match the color of your window background, and window-divider-right-width to 1, (both in the customization group window-divider, the bar is 'invisible'
    – Tyler
    Commented Jul 18, 2018 at 14:51
  • 1
    Or if you keep the fringe, just set the color of window-divider to match your fringe
    – Tyler
    Commented Jul 18, 2018 at 14:52

This is the vertical-border. You can set it like this:

(set-face-foreground 'vertical-border "green")

I don't know if it's possible to set the width, any further customisation would probably be done using window-divider-mode which 'covers' the vertical-border when it is turned on.


With window-divider-mode activated, you can set the divider width in your config.

(setq window-divider-default-right-width 3)

It makes much easier to reorganize buffer sizes with the mouse, imho, but some people won't like that.

  • 1
    note that you need to call window-diiver-mode after the setq
    – Gangula
    Commented Jun 23 at 10:44

To be more clear for future users.

set-fringe-mode: controls the gap between the extreme right & left borders of the Window and the inside it

(set-fringe-mode 10) ;; set 10 units gap around

scroll-bar-mode can control if scroll bar is visible or hidden - documentation

(scroll-bar-mode 0) ;; hide the scroll bar

window-divider-mode - controls the gap between the windows inside Emacs when you split windows like (split-window-right) - documentation

(setq window-divider-default-right-width 5)   ; width of the the divider between windows
(set-face-foreground 'vertical-border "#00ff00")  ;; color of the border
(window-divider-mode 1)     ; Display a border/divider between windows

related to this

visual-fill-column-mode - controls the amount of text to be displayed in 1 line

(setq visual-fill-column-width 160 ;; this is like the width of a page in a book
      visual-fill-column-center-text t) ;; center the buffer content in the window
(visual-fill-column-mode 1)) ;; enable visual-fill-column-mode

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.