The formula for compound interest on a single deposit is: a = d ((1 + ( r / n )) ^ (n * p))

- a — the amount of money you will have at the end of the deposit period

- d — your initial deposit

- r — the annual interest rate expressed as a decimal

- n — the number of compounding periods per year — e.g. monthly = 12

- p — the number of years your money will be in savings and you will accrue interest
Keep in mind that this is a simple formula, and when calculating the compounding interest on an amount which includes a frequent deposit, you’ll need to alter the way you calculate the interest.
This is because your compounding interest will be calculated at the beginning of the deposit period, where interest is added to the initial amount plus any deposits.
For example:
You deposit $10,000 for a fixed term and make regular deposits of $1,000 each month. The compounding interest is 5.00% and calculated annually, so for your first year, the amount of interest will only be $500 — where 5 per cent of 10,000 is 500. The total amount at the end of that year in your account will be 10,000 plus interest (500) plus your deposits (12,000), so the total amount will be $22,500.
For the next year, the 5.00% interest will be applied to the starting amount (22,500) so your interest will be $1,125. The total amount at the end of the second year will be the starting amount (22,500) plus the interest (1,125) plus the deposits (12,000), so your total amount at the end of the second year will be $35,625.