I want my primary display be at the right and my TV (additional) be at the left.
In that case new windows shall appear at the TV.
Can I somehow set where new windows will appear ?

- 4,500

- 886
- 1
- 6
- 6
-
A more technical approach (pre-userspace, therefore also pre-X window) would be to use kernel parameters/options. They allow you to set this at the framebuffer console level (which driver gets mapped to which console): https://superuser.com/questions/122173/change-linux-consoles-default-monitor – Jonathan Komar Apr 05 '19 at 07:39
-
It seems like the body of your question refers only to a window manager, but the title might lead people towards: https://unix.stackexchange.com/questions/5263/is-it-possible-to-control-which-monitor-is-considered-the-primary-monitor, https://askubuntu.com/questions/418607/dual-monitor-setup-grub-loader-goes-to-hdtv-even-if-it-is-turned-off, https://superuser.com/questions/895988/how-do-i-change-which-monitor-my-computer-uses-at-boot – Jonathan Komar Apr 05 '19 at 08:09
21 Answers
Turn off the current Primary monitor in "Displays" application and apply.
The secondary monitor will become the Primary. Then simply turn the old primary monitor again to have both displays active again.
-
5
-
3
-
12That doesn't do the trick. What you are doing with that is essentially the same as dragging the monitor you want to be the primary to the left side. It's ok if you want it to be on the left. But if you want it to be on the right you'll have to drag it to the right at the end of your procedure...which makes the left one the primary again. – mmalmeida Feb 24 '15 at 09:44
-
12
-
3
-
In my case it's necessary to combine with editing
~/.config/monitors.xml
like described in the other answer. This bug has been confirmed 2015-03-28. There's a huge split between the meaning of Ubuntu and the fact that there're five popular FLOSS desktops develped in parallel and either none of them figures out how to arrange displays or all of them are talking past each other. – Kalle Richter Nov 26 '17 at 01:12 -
The only correct answer here is unfortunately a buried comment:
I've reported this at https://bugs.launchpad.net/unity/+bug/1425000 – mmalmeida
It seems that the primary one (at least in 14.04) is always the one closest to the top left. So, there's no way to make the "right" display the primary one. Editing ~/.config/monitors.xml
makes no difference.
(As this question pre-dates 14.04, I'm guessing this has been an issue for a while now)

- 1,521
-
1The bug is also in 12.04. No way to get the right monitor to be the primary. – mivk Nov 14 '15 at 09:35
For what it's worth at this point, you can adjust which monitor is the primary by dragging the menu bar from one monitor to the other.
- Go to
System Settings
>Displays
- Hover over the menu bar on your secondary monitor
- Click and drag it over to your preferred primary
- You can also adjust the
Launcher Placement
dropdown to reflect which monitor you want it on, or on all monitors if you prefer. - Click
Apply

- 379
-
4This should be the accepted answer! The others are, at best, workarounds. – k0pernikus Dec 09 '15 at 11:08
-
1Doesn't work for me on 14.04. Say I have a focused window on my (intended) primary screen, switch workspaces, then switch to the previous workspace. Now the window doesn't have the focus anymore, because the "secondary" screen steals focus, i.e. it is indeed primary despite applying these instructions. – arekolek Dec 21 '15 at 09:21
-
launcher placement is the trick here.that means any app that you launched will up in your monitor that you specified in launcher placement – erginduran May 07 '17 at 20:14
-
-
-
Change from 'all' to 'green' and back to 'all' and now green is the primary monitor. – Mark Jeronimus Sep 04 '18 at 12:22
The following answer enables the monitor on the right to be the primary monitor (Ubuntu 14.04)
The key idea is to edit ~/.config/monitors.xml
with your favorite editor.
Identify you main monitor (name, resolution, etc) and change no
into:
<primary>yes</primary>

- 117,780

- 667
- 1
- 6
- 20
-
3
-
Doesn't work for me, just like the other answer. Restarting my session with ctrl+alt+backspace didn't help. – arekolek Dec 21 '15 at 09:33
-
1
-
1Ubuntu 16.04.1. My monitor (on the right) was already marked
<primary>yes</primary>
, and new windows still open on the laptop display (which is on the left). – Dan Dascalescu Sep 12 '16 at 04:04 -
@DanDascalescu Same here. What I did was move my main monitor to the top in the "Displays" settings. So, to get to the left monitor, I have to move my mouse down, which is better than having to move my mouse to the right so it ends up on the left monitor. – Joschua Sep 23 '16 at 11:15
-
2@Joschua: I gave up and solved this software bug with a hardware solution: moved my laptop to the right of the monitor. – Dan Dascalescu Sep 24 '16 at 22:41
-
This worked for me on Ubuntu 16.04 GNOME. Press Alt
then type r to restart the shell (no need to logout etc) and this change will take effect. – Dodgyrabbit Mar 06 '18 at 16:13
If you are running an Nvidia card (with Nvidia drivers), you can use their settings tools to set the primary monitor. The Nvidia drivers have more options than the native Ubuntu monitor configuration.
Run the following command to start the Nvidia Settings Configuration
sudo nvidia-settings
If this command isn't found, this solution will not work until you install the Nvidia drivers.
Select the "X Server Display Configuration" tab on the left.
Select the monitor you want to be primary (in my example, I want the LGD display to be primary).
Check the "Make this the primary display for the X screen" checkbox, then hit "Apply".
Quit the settings window, then run this to make this change persistent through reboots:
sudo nvidia-xconfig
I had this issue before, and I had some wacky monitor setups. This has always worked for me (on 16.04 right now), hope it will work for anyone else out there with Nvidia!

- 3,783
- 2
- 25
- 38
If I'm not mistaken if you do the following
- Click on the Power button
- Go into the Display menu
- Rearrange your two monitors in the way you like by dragging the highlighted screens as below (there will be 2 in your case):
- And then making sure the launcher placement is on your primary screen, then should do the trick I'd assume.

- 1,919
-
4In that case primary wll be the left! I want my primary display be at the right! – emoxam May 27 '13 at 14:41
-
If I'm not mistaken (can't try this right now unfortunately) you can drag the displays (as in the red Laptop and Green other screen in your case) around to have the primary on the right. And after changing the launcher placement it should work, did you give it a try? – Oyibo May 27 '13 at 14:44
-
Ok, i have two monitors, i make my TV at right, and monitor at left, all windows moved to TV, i get them back to monitor by hands, and now i have a problem - i have the upper panel on every display and pidgin shown only on TV;s panel tray. That what i am about, why pidgin's icon at the TV only ? (I guess i will have similar problems from time to time) – emoxam May 27 '13 at 15:48
In Ubuntu 18.04 its possible but hard to find. Under "Settings->Devices->Screen Display" one may find a section called "Primary Display". You can actually click on the label, although there is no indication.

- 2,440
- 6
- 34
- 53
-
1Only thing that worked for me on 18.04, the other answers appear to apply to earlier versions. – Bas Swinckels Dec 22 '20 at 07:46
In Ubuntu 17.04
I was able to change the primary display, via the settings > Devices > Displays and change the primary display option to your extended display.

- 203
-
I confirm this feature is working well also in Ubuntu 18.04.1 LTS. Open "Displays" application, go to display arrangement, and in the lower bar of this frame, there you'll find "Primary Display" - select and enjoy! – Hartmut Pfarr Aug 21 '18 at 09:59
Another way using XRANDR command
Check for available connections names
xrandr
Screen 0: minimum 8 x 8, current 2806 x 900, maximum 32767 x 32767 LVDS1 connected primary 1366x768+0+0 (normal left inverted right x axis y axis) 309mm x 173mm 1366x768 60.07*+ 40.02 1360x768 59.80 59.96 1280x720 60.00 1024x768 60.00 1024x576 60.00 960x540 60.00 800x600 60.32 56.25 864x486 60.00 640x480 59.94 720x405 60.00 680x384 60.00 640x360 60.00 DP1 disconnected (normal left inverted right x axis y axis) DP2 disconnected (normal left inverted right x axis y axis) DP3 disconnected (normal left inverted right x axis y axis) HDMI1 disconnected (normal left inverted right x axis y axis) HDMI2 disconnected (normal left inverted right x axis y axis) HDMI3 disconnected (normal left inverted right x axis y axis) VGA1 connected 1440x900+1366+0 (normal left inverted right x axis y axis) 370mm x 230mm 1440x900 59.89*+ 74.98 1280x1024 75.02 60.02 1280x800 59.81 1152x864 75.00 1024x768 75.08 70.07 60.00 832x624 74.55 800x600 72.19 75.00 60.32 56.25 640x480 75.00 72.81 66.67 60.00 720x400 70.08 VIRTUAL1 disconnected (normal left inverted right x axis y axis)
So as you see LDVS1 connected primary, to change VGA1 as primary run:
xrandr --output VGA1 --primary
Check again:
xrandr
Screen 0: minimum 8 x 8, current 2806 x 900, maximum 32767 x 32767 LVDS1 connected 1366x768+0+0 (normal left inverted right x axis y axis) 309mm x 173mm 1366x768 60.07*+ 40.02 1360x768 59.80 59.96 1280x720 60.00 1024x768 60.00 1024x576 60.00 960x540 60.00 800x600 60.32 56.25 864x486 60.00 640x480 59.94 720x405 60.00 680x384 60.00 640x360 60.00 DP1 disconnected (normal left inverted right x axis y axis) DP2 disconnected (normal left inverted right x axis y axis) DP3 disconnected (normal left inverted right x axis y axis) HDMI1 disconnected (normal left inverted right x axis y axis) HDMI2 disconnected (normal left inverted right x axis y axis) HDMI3 disconnected (normal left inverted right x axis y axis) VGA1 connected primary 1440x900+1366+0 (normal left inverted right x axis y axis) 370mm x 230mm 1440x900 59.89*+ 74.98 1280x1024 75.02 60.02 1280x800 59.81 1152x864 75.00 1024x768 75.08 70.07 60.00 832x624 74.55 800x600 72.19 75.00 60.32 56.25 640x480 75.00 72.81 66.67 60.00 720x400 70.08 VIRTUAL1 disconnected (normal left inverted right x axis y axis)

- 48,105
Solution: I know this is an old thread but the solutions posted here didn't work for me on Ubuntu 16.04 (but the xrandr answer posted here helped point me in the right direction) For posterity and to help other people searching for an answer...
A full answer that fully solved this problem for me can be found at the following link if it helps anyone else who is struggling with this issue: Set primary monitor on 16.04
-
5Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. – Kalle Richter Aug 12 '16 at 08:22
In Ubuntu 18.04 there is an option to set the primary display.
Devices>Display Arrangement>Primary Display.
There is also an extension if you want to quickly switch between display modes. https://extensions.gnome.org/extension/1030/display-switcher/

- 10,783

- 101
In Ubuntu 18.04.3 LTS (gnome) go to Settings > Devices > Displays > Primary Display

- 101
Yes. Start System settings, click on Displays then drag the monitors so that they are where you want them to be.

- 4,813
- 8
- 35
- 52
-
2In that case primary wll be the left! I want my primary display be at the right! – emoxam May 27 '13 at 14:39
-
-
Ok, i have two monitors, i make my TV at right, and monitor at left, all windows moved to TV, i get them back to monitor by hands, and now i have a problem - i have the upper panel on every display and pidgin shown only on TV;s panel tray. That what i am about, why pidgin's icon at the TV only ? (I guess i will have similar problems from time to time) – emoxam May 27 '13 at 17:02
For people running the newer versions (working on 16.04), you can easily change the position of your monitors by drag-drop. The leftmost display will become your primary display.
For example - I've my laptop connected to external display which is placed on the left on my desk. So I've to drag the external display icon (see in image) from the right to the left of Built-in display.
-
In Ubuntu 18.04 Unity, dragging to the left does not make it a main display. – tartaruga_casco_mole Apr 27 '18 at 21:42
-
Not using Ubuntu anymore but I think they've moved to Gnome now – Divyanshu Maithani Apr 28 '18 at 08:36
In Ubuntu 20.04, with kernel 5.8.x I found that there is a "feature" that will require you to set ONLY ONE monitor (the attached one). Then go back, and this time the drop-down list pointed by Adam will be available for you to configure two monitors and decide the primary one.
Kubuntu 18.04
- Open System Settings.
- Go to Display and Monitor > Displays.
- Click the dropdown next to Primary display.
- Select the desired display.
- Click Apply to save.

- 484
Easy solution.
Toggle off all the monitors via the Displays settings.
Toggle on only the monitor that you wish will be the main one. This will force him to be the main monitor.
Apply changes.
Toggle on the rest.
Work for me in ubuntu 22.04 LTS and kernel 5.15.0-25-generic
Yes, there is a "default monitor" setting, and it's usually accessible from the Graphics Utilities Control Panel. So look for or install your Nvidia or ATI cards control panel software.

- 1,361
-
Would you please provide me a screenshow ? I can't find it in a amdcccle util. – emoxam May 27 '13 at 14:40
I'm using kubuntu 13.04, live with 2 Gb persistence. I have a laptop with a 2nd monitor on the left. The Displays Setting worked perfectly (Take that! Debian 7 Live, Fedora Live!) but then windows would open on my 2ndry monitor. I opened display settings, set the the 2nd mon as primary, hit Apply, then set my primary mon as primary, hit Apply, & all works fine.

- 139
- 4
-
I'm using Lubuntu 20.04 My secondary monitor (on the left) is designated as "This screen extends another display" (one of two choices) in Monitor Settings. My laptop display (on the right) is designated as "This is my primary display." All new windows and notifications appear on my secondary display although the task panel is on my primary display. I'm glad your technique works for you; it doesn't for me. Should I report this as a bug? – Geoffrey Wheeler May 13 '20 at 19:27
I got the trick. In the Display setting you see both scree BUT the primary display have a title bar with the date at the up. You need to click on this bar and drag it to the monitor you want primary. Apply et voila
-
3This answer doesn't add anything useful. drunkScientist already gave the same answer, and there was already a reply that it's wrong. – Dan Dascalescu Sep 12 '16 at 04:06
you might be looking to click on that little black bar on the monitor selection pic above, sets where the menu is, which seems to also be the default monitor. worked for me with 12.04 and gnome

- 1
- 1
- 6
-
2no, this is not a default monitor. Even if unity panel is displayed only at the left, right monitor still is considered as primary. For instance truecrypt window when launched appears on it, instead of left monitor – d.k Feb 17 '14 at 11:54