There is a file size limit, though I don't know what that limit is with this XenForo forum software that TPF now uses.
Before the file size limit was about 2.5 Mb.
File size is not the pixel dimensions (image resolution) of your photo, however, reducing the image resolution (pixel dimensions) does also reduce the file size.
The forum software will automatically adjust the image resolution for you. You only need to be cognizant of the file size.
8-bit JPEG, TIFF, PNG, GIF and similar 8-bit file types are appropriate.
The Internet is pretty much limited to sRGB for an images color space. If your photo is in some other color space (like Adobe RGB or ProPhotoRGB), or has a bit-depth of more than 8-bits, convert your photo to an 8-bit color depth and the sRGB color space.