[4.6 2D] Making UI image stick to the side

I have a simple scene, in it is a simple initial design of having a sidebar with some options(Mute music, mute effects, main menu) on it, but I’m facing a problem when placing it to the side, I try and place the anchors(I frankly don’t know much on how they work, but I followed some tips I read and so far they work), everything looks fine in the editor view, but in the game view when maximizing the sidebar moves a bit to the center, making it floating instead of sticking to the side.


  1. how I want it to be(Edit view):

  2. How it looks in the game view when maximized or it has a high enough resolution:

You can notice it slightly floating to the left, now that might be minor, but it irritates me, it’s an initial design with nothing final, but I would like to solve the problem with your generous help, simply knowing how to make it snap to the sides if that’s the appropriate word for what I want to do.

Thank you.

You can set your anchor to middle right. That should all ways have a fixed position to the vertical middle on the right side.
Setting the pivot of you element to 1 could help too.
I can recommend the UI Rect Transform Tutorial for good overview over the Anchor.