# How to center align the whole table? [duplicate]

I created a table and it starts from the left and goes all the way to right, which looks really skewed. So I want to center align the whole table but couldn't figure out how to do it. I'm new to latex so I don't know how to use other plugin or macros, but I suppose there's a command for this basic functionality. Can anyone tell me?

## migrated from stackoverflow.comMar 12 '13 at 9:44

This question came from our site for professional and enthusiast programmers.

If this is inside a float like the table environment, I'd suggest

\begin{table}[htbp]
\centering % center but don't add vertical space

Using the center environment inside a float is not recommended as it adds vertical space above and below, which the float will also do, resulting in too much space.