I have been puzzling over where to put the submit button, on the left or the right. In researching, I noticed that many sites put buttons on the bottom right in dialogue boxes, and on the bottom left in forms.
It makes sense: in a dialogue box it seems to denote finality, being in the endpoint of the window for left–right readers; in a form, the bottom right could be in a different position relative to the rest of the form if the window is resized.
It seems to be a convention, but should the OK/Cancel buttons be aligned right or centered?
Should the OK/Cancel buttons be aligned right or centered?
I don't want to be a design police, just a designer looking for guidance on this matter!
A good user interface should allow for a consistent experience for users. Placing the OK/Cancel buttons on the bottom right is a common convention in user interfaces because it provides a clear visual distinction between the two buttons and makes it easy for users to identify the primary action (OK) and the secondary (or cancel) action. Centering the buttons or placing them on the left could
Here are the relevant examples I could find:

- Google Drive “Add file” dialog: The OK button is aligned to the bottom right, and Cancel is centred.
- Visual Studio Code: The OK button is aligned to the right, the Cancel button is aligned to the left, and the Save and Cancel buttons are centred.
- Microsoft Word, Excel: The OK button is aligned to the right, Cancel is centred, Apply is the default