In this course, we delve into the stochastic foundations of mathematical finance, focusing on the general problem of pricing and hedging European contingent claims and portfolio optimisation. We rigorously define the concept of a financial market and establish two fundamental relationships: one between arbitrage-free markets and the existence of equivalent martingale measures, and the other concerning the completeness of a market and the uniqueness of the equivalent martingale measure. We explore various methodologies for pricing and hedging contingent claims in complete and incomplete markets, including risk-neutral, variance-optimal, and utility and risk-indifferent approaches. We also examine how market participants' preferences can be quantified using utility functions and risk measures, and how these concepts are applied in portfolio optimisation. Furthermore, we discuss the formulation of consumption-investment problems as stochastic optimal control problems and introduce dynamic programming as a general solution method. This course provides students with a thorough understanding of the core principles of mathematical finance and their application in financial decision-making and risk management under uncertainty.