The electron configuration for Aluminum is
1s22s22P663s23P1
The first 10 electrons are in the filled first and second shells.
This leaves only three electrons in the third shell 3s23p1
13−10=3
so there are only 3 valance electrons