They really have nothing to do with each other. Parameters are values that are submitted as part of the HTTP request to the servlet, while attributes (also known as "scoped variables") are values created by the servlets and stored in one of the various scopes.
Vijitha Kumara wrote:You can use parameters with the request URL(s)
Not quite accurate. You don't really "use" parameters with URLs. But as I stated, servlet parameters are the result of request parameters submitted on an HTTP request. Whether the parameter data is carried on the URL or within the request body depends upon the type of the request.
but you can store attributes in various objects like ServletRequest, HttpSession, ServletContext and also in PageContext for JSP.
Yes, those are the scopes that I mentioned. Page scope is not available from servlets.
subject: different between parameters and attributes