From: Ten Principles of Judaism
Judaism teaches us that ritual without ethics is not only fruitless, but idolatrous and anti-religious. Ritual serves the purpose of implementing and embodying the ethical and spiritual dimensions of Judaism. Ritual should never be a substitute for ethics or charitable acts.
Ethics and ritual must have their proper place in Judaism. However, in the Bible and in Judaism, ethics trumps ritual in the sense that one cannot engage in ritual for immoral purposes like curses, incantations, or to bribe and propitiate God.
Leviticus 19 clearly states that the foundation for holiness is ethical action. Nothing can be holy if it is unethical. Ethics are not only superior to ritual practice, but ritual practice must be the implementation of the ethical.