Question: can you impeached a president for something done before taking office

Answer: Yes, Impeachment in the United States is the process by which the lower house of a legislature brings charges against a civil officer of government for crimes alleged to have been committed, analogous to the bringing of an indictment by a grand jury. At the federal level, this is at the discretion of the House of Representatives. Most impeachments have concerned alleged crimes committed while in office, though there have been a few cases in which officials have been impeached and subsequently convicted for crimes committed prior to taking office. The impeached official remains in office until a trial is held. That trial, and their removal from office if convicted, is separate from the act of impeachment itself. Analogous to a trial before a judge and jury, these proceedings are (where the legislature is bicameral) conducted by upper house of the legislature, which at the federal level is the Senate.