Is it by whom or by who?

By whom (not “by who”) is the correct choice at the beginning of a question (e.g., “By whom was it written?”).

But “whom” has a very formal stylistic effect, which you may want to avoid, so in most everyday contexts it is better to use “who” and put the preposition “by” at the end (e.g., “Who was it written by?”).

“By whom” (not “by who”) is also the grammatically correct choice at the beginning of an adjective clause (e.g., “The Rector, by whom he was appointed, made no comment”). But again, “who” is often the better option, with “by” in a later position (e.g., “The Rector, who he was appointed by, made no comment”).

The QuillBot Grammar Checker can help ensure you’re using “who” and “whom” correctly.