What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.

  • Profile Image

    Is it possible to center align a text box?

    Asked by FRJotform on May 12, 2017 at 09:07 AM

    Is it possible to center align a text box (the object, not the text within it) rather than it always being aligned to the left of the page?

    Is there some custom CSS that I could use for this?

    I have previously done this by setting the width of the box and then changing the margin it's aligned against but this isn't really suitable for my uses.


  • Profile Image
    JotForm Support

    Answered by amy on May 12, 2017 at 10:31 AM


    First of all, I would like to recommend you to shrink the text box. You can shrink it by clicking on "Properties" and then going to the "Advanced" tab. 

    Then please find the ID of the field on the same page by clicking on the "Field Details" button:

    Finally, please inject this custom CSS code to your form. Please don't forget to change the field ID. You can also change the value of the margin according to your own preference:

    #input_22 {

    margin-left: 85%;  


    How to Inject Custom CSS Codes

    The result:

    Please send us further details such as the form URL etc. if you cannot succeed this way.

    Thank you.

    All the best!