Conversation so far:
What were his ideas about?
The Theodicy tries to justify the apparent imperfections of the world by claiming that it is optimal among all possible worlds.
Was he spiritual or religious?
Leibniz asserted that the truths of theology (religion) and philosophy cannot contradict each other, since reason and faith are both "gifts of God.
Did others agree with him?
CANNOTANSWER.
Was he optimistic because of his beliefs and that he saw a purpose in things such as religion and philosophy?
if God is all good, all wise and all powerful, how did evil come into the world?
The answer (according to Leibniz) is that, while God is indeed unlimited.

Question: What does he believe God caused evil?
Self-contained rewrite: What does Gottfried Wilhelm believe God caused evil?