The answer is VI or VII, depending on whether the numbering is done inclusively or exclusively of the uncrowned James Francis Edward Stuart, who is recognised as James VIII by Jacobites. James' father is James VII of Scotland and II of England and Ireland.
Royal Contender or Pretender? The James Francis Edward Stuart Challenge