I want to send email with Arabic content through java mail ,
but every Arabic word in the message appears like ????????????? ,
how can i make the encoding to utf_8 in order to support Arabic language ???
since i use that code
Message message = new MimeMessage(session);
message.setFrom(new InternetAddress(from));
message.setRecipients(Message.RecipientType.TO, InternetAddress.parse(to, false));
message.setSubject(subject_a);
message.setText(messageDetails_a);
Transport.send(message);
Just add some charset-information to the methods. If subject or message-body does contain other than US-ASCII characters, the default charset will be used for encoding. Explicitly setting the charset to UTF-8 will always be safe: