It will be based on percentile. Your raw marks will be converted into normalized score called as percentile. Percentile is calculated taking into many factors like total no of students. No of students above your marks.
So after both the JEE exam are over NTA will generate rank based on percentile
Regular exam updates, QnA, Predictors, College Applications & E-books now on your Mobile