You always start by getting back your wager, and then you get the odds as profit. So, for “2 to 3” odds, if you bet $3 (and win) you’d get the $3 back plus $2 profit for a total of $5.
Another, more likely, example: If you bet $2 on a 3 to 1 odds horse, and it wins, you get your $2 plus 3X$2=$6 for a grand total of $8.
Last example: If you bet 10$ on a 3 to 5 odds horse, and it wins, you get your $10 back plus $3 for every $5 you bet (total 2X$3=$6) for a grand total of $16.