early 15c. in a literal sense, from flat (adj.) + -ly (2). Meaning "in a plain manner" is from 1560s; sense of "in a dull manner" is from 1640s.
he flatly denied the charges