I often get stuck when forming or formatting a sentence with one or more parentheses. For example, I wrote an answer on another Stack Exchange site, in which I wrote:

...whereas, my phone(xperia x10 mini) comes with several widgets...

which, afterwards, I thought should be:

...whereas, my phone (xperia x10 mini) comes with several widgets...

But in some cases I feel the former way is correct, like:

... phones which have a camera include IPhone(5MP), Nokia N8(12MP), Nokia X6(3MP)....

Is there any rule for the placement of space after and before parentheses?

  • 4
    Related note: Proper convention is a space between the numeral and the unit, e.g. (5 MP). Commented May 9, 2011 at 23:18

7 Answers 7


The one rule remains readability.

No space before a parenthesis is usually used with functions:


Since your technical description of camera isn't a "function", I would still go with:

...phones which have camera include IPhone (5MP), Nokia N8 (12MP), Nokia X6 (3MP)

That being said, if you have a consistent convention throughout your document with no space before parenthesis, you could go with it.

But as you illustrate in your question, there are instances where a space is needed. 

  • Hehe, I like how you address the programming syntax first... and then the text case! Good answer, anyway.
    – Noldorin
    Commented Dec 1, 2010 at 17:16
  • It's not programming syntax, it's math. sighhh English majors...
    – NoName
    Commented Jul 3, 2017 at 8:33

Ordinarily a parenthesis (pl: parentheses) introduces a term or clause that modifies whatever precedes it. It would be preceded by a space and followed by whatever would otherwise follow that term in the absence of the parenthetical remark (e.g., a space, comma, or period).

In mathematics, science, marketing (there's a strange set of bedfellows!), and in certain abbreviations, a parenthesis may be part of a term. As such it serves purely as a character rather than having the functional role of introducing a modifier. It would be as incorrect to insert anything before the parenthesis-qua-character as it would be to put arbitrary spaces within any word.

Thus, preceding a parenthesis (or opening bracket of any kind, such as "[" or "{") by a space provides a clear and well-understood mechanism to distinguish these two uses. For example, we would read "IPhone(5MP)" as being the full name of a particular kind of IPhone, whereas "IPhone (5MP)" would refer to something whose name is "IPhone" which happened to have the "5MP" property. That is a subtle distinction in this case, but perhaps it's strong enough to permit a reasoned choice concerning the usage that best conveys the intended thought.

  • 3
    Nicely explained. +1
    – VonC
    Commented Dec 2, 2010 at 4:56
  • 1
    This is a great answer because it explains the why which is ultimately better than saying "whatever is more readable" or "such-and-such is the convention."
    – JYelton
    Commented Sep 19, 2013 at 0:36
  • 1
    I would still use a space even if "(5MP)" is part of the product name. Marketing isn't really comparable to maths or science, because in marketing they don't feel any need to follow conventions.
    – nnnnnn
    Commented Aug 7, 2019 at 1:41

When writing in English (not a programming language or math), the rule is: put a space before the opening parenthesis, and either a space or a punctuation mark after the closing parenthesis. Do not put a space after the opening or before the closing parenthesis. In other words, there shouldn't be any space between the parentheses and what they enclose, but there should be spaces around the parenthetical clause.

If you're writing in a language other than English, e.g. a mathematical equation or a programming language, naturally you need to use the rules of that language instead.

  • Agreed. But note that with some programming languages use of spaces can be a matter of convention to make the code easier for people to read, not a requirement of the language itself in order for the program to work.
    – nnnnnn
    Commented Aug 7, 2019 at 1:46
  • Just a minor point: you'd put a punctuation mark before the closing parenthesis if the parentheses contain a capitalised sentence. Commented Nov 13, 2022 at 20:47
  • @schrödingcöder: hence "either a space or a punctuation mark after the closing parenthesis" (emphasis added). If there's already a punctuation mark before the closing parenthesis, then naturally you go with the space after it.
    – Marthaª
    Commented Nov 14, 2022 at 15:54
  • Oops! Sorry. My bad. Shall I remove my comment(s) then? Or should it be comment (s)? Commented Nov 14, 2022 at 17:35

If I saw your last example while editing your piece, I would add spaces. That is, at best, an unconventional way to use parentheses.

  • unconventional in the sense, not recommended?
    – lalli
    Commented Dec 1, 2010 at 7:17
  • 7
    Yes, I would say that most people who read a lot would say it looks "wrong." It won't impede understanding, but it is not the way it is usually done.
    – kindall
    Commented Dec 1, 2010 at 7:19

Like the first answer, f(x) -> no space before opening parenthesis

Treat the closing parenthesis as ending a word => suffix a space if it's followed by another word and not a punctuation marker (full-stop, comma, [semi-]colon, etc.).


A space after and before the word in parenthesis. Exception, when there's a punctuation after the parenthesis (,.;:).

You only use it with no space to the previous word when is a math function, x(4+2) + y(2*2).


I agree that a space is required in your example. Grouping of the product name and its parenthesized resolution is achieved with the use of commas.

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