JSP files end with the .jsp suffix. The encoding for each top-level JSP file is specified using a header at the top of the file. The header must look like the following:
<%@ page contentType="text/html; charset=encoding" %>
where encoding is the desired encoding such as UTF-8 or EUC-JP. Note that this is only for top-level JSP files. JSPs that are statically included by other JSPs must use the encoding of the including JSP. That is, JSPs that are statically included by other JSPs using
<%@ include file="relativeURL" %>
must use the encoding of the including JSP. JSPs that are dynamically included using:
<jsp:include page="{ relativeURL | <%= expression %>}" flush="true" />
must have their own page directive that contains the encoding.